diff options
author | Kaz Kylheku <kaz@kylheku.com> | 2018-06-22 06:46:05 -0700 |
---|---|---|
committer | Kaz Kylheku <kaz@kylheku.com> | 2018-06-22 06:46:05 -0700 |
commit | 8628fd0133fd7796491b2927023a97c3ec5f5ce3 (patch) | |
tree | 4bd74fd250c998db24aa8491dfa13b4ab0c53dbf | |
parent | 46480c25e62f60c761088c561d90b0f2f5a3143f (diff) | |
download | txr-8628fd0133fd7796491b2927023a97c3ec5f5ce3.tar.gz txr-8628fd0133fd7796491b2927023a97c3ec5f5ce3.tar.bz2 txr-8628fd0133fd7796491b2927023a97c3ec5f5ce3.zip |
hash: fix broken equality-of-two-hashes test.
* hash.c (hash_equal_op): Fix broken logic that is supposed to
push a cell onto the pending list: rplaca should be rplacd.
-rw-r--r-- | hash.c | 4 |
1 files changed, 2 insertions, 2 deletions
@@ -345,7 +345,7 @@ static val hash_equal_op(val left, val right) } else { ncons = or2(pop(&free_conses), cons(nil, nil)); rplaca(ncons, lcell); - rplaca(ncons, pending); + rplacd(ncons, pending); pending = ncons; } @@ -364,7 +364,7 @@ static val hash_equal_op(val left, val right) } else { ncons = or2(pop(&free_conses), cons(nil, nil)); rplaca(ncons, rcell); - rplaca(ncons, pending); + rplacd(ncons, pending); pending = ncons; } } |