aboutsummaryrefslogtreecommitdiff
path: root/src/interp/hashcode.boot
diff options
context:
space:
mode:
Diffstat (limited to 'src/interp/hashcode.boot')
-rw-r--r--src/interp/hashcode.boot8
1 files changed, 4 insertions, 4 deletions
diff --git a/src/interp/hashcode.boot b/src/interp/hashcode.boot
index 96161cc9..1b49d977 100644
--- a/src/interp/hashcode.boot
+++ b/src/interp/hashcode.boot
@@ -48,15 +48,15 @@ hashType(type, percentHash) ==
symbol? type =>
type = '$ => percentHash
type = "%" => percentHash
- hashString SYMBOL_-NAME type
+ hashString symbolName type
string? type => hashCombine(hashString type,
hashString('"Enumeration"))
type is ['QUOTE, val] => hashType(val, percentHash)
- type is [dom] => hashString SYMBOL_-NAME dom
+ type is [dom] => hashString symbolName dom
type is ['_:, ., type2] => hashType(type2, percentHash)
isDomain type => getDomainHash type
[op, :args] := type
- hash := hashString SYMBOL_-NAME op
+ hash := hashString symbolName op
op = 'Mapping =>
hash := hashString '"->"
[retType, :mapArgs] := args
@@ -95,7 +95,7 @@ $hashModulus := 1073741789 -- largest 30-bit prime
hashString str ==
h := 0
for i in 0..#str-1 repeat
- j := CHAR_-CODE char str.i
+ j := codePoint char str.i
h := LOGXOR(h, ASH(h, 8))
h := h + j + 200041
h := LOGAND(h, 1073741823) -- 0x3FFFFFFF