fix `print-convert' on cyclic hash key
Closes PR 12373
This commit is contained in:
parent
dd0a49bc62
commit
0772cdf2e3
|
@ -144,6 +144,7 @@
|
||||||
(hash-table-for-each
|
(hash-table-for-each
|
||||||
expr
|
expr
|
||||||
(lambda (key value)
|
(lambda (key value)
|
||||||
|
(build key)
|
||||||
(build value))))]
|
(build value))))]
|
||||||
[(pair? expr)
|
[(pair? expr)
|
||||||
(unless (build-sub expr)
|
(unless (build-sub expr)
|
||||||
|
|
|
@ -319,7 +319,15 @@
|
||||||
(-4- `(1 . ,-5-))
|
(-4- `(1 . ,-5-))
|
||||||
(-5- `(2 3))
|
(-5- `(2 3))
|
||||||
(-8- `(,-4- ,-5- (2 3))))
|
(-8- `(,-4- ,-5- (2 3))))
|
||||||
-0-))))
|
-0-))
|
||||||
|
(make-pctest (read (open-input-string "#hasheq((#0=(1 . #0#) . a))"))
|
||||||
|
'(shared ((-1- (cons 1 -1-))) (make-hasheq (list (cons -1- 'a))))
|
||||||
|
'(shared ((-1- (cons 1 -1-))) (make-hasheq (list (cons -1- 'a))))
|
||||||
|
'(shared ((-1- (cons 1 -1-))) (make-hasheq (list (cons -1- 'a))))
|
||||||
|
'(shared ((-1- `(1 unquote -1-))) (make-hasheq (list (cons -1- 'a))))
|
||||||
|
'(shared ((-1- `(1 unquote -1-))) (make-hasheq (list (cons -1- 'a))))
|
||||||
|
'(shared ((-1- `(1 unquote -1-))) (make-hasheq (list (cons -1- 'a))))
|
||||||
|
'(shared ((-1- (cons 1 -1-))) (make-hasheq (list (cons -1- 'a)))))))
|
||||||
(for-each run-test tests))
|
(for-each run-test tests))
|
||||||
|
|
||||||
(let ()
|
(let ()
|
||||||
|
|
Loading…
Reference in New Issue
Block a user