Skip to main content

Module hash

Module hash 

Source
Expand description

Port of src/parser/utils/hash.ts.

The typescript hash() is async because of crypto.subtle.digest(): the rust digests are synchronous, hash() and sync_hash() share the implementation (sync_hash() rejects the sha algorithms, like syncHash()).

Constants§

DIGITS
HASH_ALGORITHMS
supported hash algorithms
LOWER

Functions§

hash
generate a hash (hash())
hash_id
generate a hash id
node_signature
structural signature of a node or a token: type, name, values, tokens and children
sync_hash
generate a hash (syncHash()): the sha algorithms are not supported