diff options
author | Kaz Kylheku <kaz@kylheku.com> | 2019-10-11 07:44:28 -0700 |
---|---|---|
committer | Kaz Kylheku <kaz@kylheku.com> | 2019-10-11 07:44:28 -0700 |
commit | 2838fb0ab11336c46bb3ed43a147c1cdf843630d (patch) | |
tree | 835b6590e4008bb38cee5a3ed22c56ed2d54fcf4 /mpi/logtab.h | |
parent | 52fed6047b4e12e50912e2561f224889cc2d035d (diff) | |
download | txr-2838fb0ab11336c46bb3ed43a147c1cdf843630d.tar.gz txr-2838fb0ab11336c46bb3ed43a147c1cdf843630d.tar.bz2 txr-2838fb0ab11336c46bb3ed43a147c1cdf843630d.zip |
hash: implement :eq-based.
We need eq based hash tables to fix a problem in *print-circle*.
* hash.c (enum hash_type, hash_type_t): New enum type.
(eq_based_k): New keyword variable.
(eq_hash, eq_hash_op): New static functions.
(hash_print_op): Ensure we print eq-based hashes with the
correct keyword.
(hash_assq, hash_aconsq_new_c): New static functions.
(hash_eq_ops): New static structure.
(do_make_hash): New function, made from previous contents of
make_seeded_hash.
(make_seeded_hash): Wrapper around do_make_hash now.
(make_eq_hash): New function.
(hashv): Parse out :eq-based argument. Use make_eq_hash if it
is present.
(hash_init): Initialize eq_based_k.
* hash.h (eq_based_k, make_eq_hash): Declared.
Diffstat (limited to 'mpi/logtab.h')
0 files changed, 0 insertions, 0 deletions