home *** CD-ROM | disk | FTP | other *** search
/ Linux Cubed Series 2: Applications / Linux Cubed Series 2 - Applications.iso / editors / emacs / xemacs / xemacs-1.006 / xemacs-1 / lib / xemacs-19.13 / lisp / oobr / hasht.elc < prev    next >
Emacs Compiled Lisp  |  1995-08-29  |  7.3 KB

open in: MacOS 8.1     |     Win98     |     DOS

view JSON data     |     view as text


This file was processed as: Emacs Compiled Lisp (other/emacsCompiledLisp).
This format is not currently supported by dexvert.

ConfidenceProgramDetectionMatch TypeSupport
1% dexvert Emacs Compiled Lisp (other/emacsCompiledLisp) magic Unsupported
1% dexvert Combustion 2 Particle Library (other/combustion2ParticleLibrary) ext Unsupported
100% file Emacs/XEmacs v19 byte-compiled Lisp data default
99% file data default
100% TrID Emacs/XEmacs byte-compiled Lisp (generic) default
100% xdgMime text/x-emacs-lisp default (weak)



hex view
+--------+-------------------------+-------------------------+--------+--------+
|00000000| 3b 45 4c 43 13 00 00 00 | 0a 3b 3b 3b 20 63 6f 6d |;ELC....|.;;; com|
|00000010| 70 69 6c 65 64 20 62 79 | 20 63 74 68 6f 6d 70 40 |piled by| cthomp@|
|00000020| 77 69 6c 6c 6f 77 2e 63 | 73 2e 75 69 75 63 2e 65 |willow.c|s.uiuc.e|
|00000030| 64 75 20 6f 6e 20 54 75 | 65 20 41 75 67 20 32 39 |du on Tu|e Aug 29|
|00000040| 20 31 34 3a 35 34 3a 34 | 31 20 31 39 39 35 0a 3b | 14:54:4|1 1995.;|
|00000050| 3b 3b 20 66 72 6f 6d 20 | 66 69 6c 65 20 2f 65 78 |;; from |file /ex|
|00000060| 70 6f 72 74 2f 77 69 6c | 6c 6f 77 33 2f 78 65 6d |port/wil|low3/xem|
|00000070| 61 63 73 2d 31 39 2e 31 | 33 2d 72 65 6c 65 61 73 |acs-19.1|3-releas|
|00000080| 65 2f 65 64 69 74 6f 72 | 2f 6c 69 73 70 2f 6f 6f |e/editor|/lisp/oo|
|00000090| 62 72 2f 68 61 73 68 74 | 2e 65 6c 0a 3b 3b 3b 20 |br/hasht|.el.;;; |
|000000a0| 65 6d 61 63 73 20 76 65 | 72 73 69 6f 6e 20 31 39 |emacs ve|rsion 19|
|000000b0| 2e 31 33 20 58 45 6d 61 | 63 73 20 4c 75 63 69 64 |.13 XEma|cs Lucid|
|000000c0| 2e 0a 3b 3b 3b 20 62 79 | 74 65 63 6f 6d 70 20 76 |..;;; by|tecomp v|
|000000d0| 65 72 73 69 6f 6e 20 32 | 2e 32 35 3b 20 31 2d 53 |ersion 2|.25; 1-S|
|000000e0| 65 70 2d 39 34 2e 0a 3b | 3b 3b 20 6f 70 74 69 6d |ep-94..;|;; optim|
|000000f0| 69 7a 61 74 69 6f 6e 20 | 69 73 20 6f 6e 2e 0a 3b |ization |is on..;|
|00000100| 3b 3b 20 74 68 69 73 20 | 66 69 6c 65 20 75 73 65 |;; this |file use|
|00000110| 73 20 6f 70 63 6f 64 65 | 73 20 77 68 69 63 68 20 |s opcode|s which |
|00000120| 64 6f 20 6e 6f 74 20 65 | 78 69 73 74 20 69 6e 20 |do not e|xist in |
|00000130| 45 6d 61 63 73 20 31 38 | 2e 0a 0a 28 69 66 20 28 |Emacs 18|...(if (|
|00000140| 61 6e 64 20 28 62 6f 75 | 6e 64 70 20 27 65 6d 61 |and (bou|ndp 'ema|
|00000150| 63 73 2d 76 65 72 73 69 | 6f 6e 29 0a 09 20 28 6f |cs-versi|on).. (o|
|00000160| 72 20 28 61 6e 64 20 28 | 62 6f 75 6e 64 70 20 27 |r (and (|boundp '|
|00000170| 65 70 6f 63 68 3a 3a 76 | 65 72 73 69 6f 6e 29 20 |epoch::v|ersion) |
|00000180| 65 70 6f 63 68 3a 3a 76 | 65 72 73 69 6f 6e 29 0a |epoch::v|ersion).|
|00000190| 09 20 20 20 20 20 28 73 | 74 72 69 6e 67 2d 6c 65 |. (s|tring-le|
|000001a0| 73 73 70 20 65 6d 61 63 | 73 2d 76 65 72 73 69 6f |ssp emac|s-versio|
|000001b0| 6e 20 22 31 39 22 29 29 | 29 0a 20 20 20 20 28 65 |n "19"))|). (e|
|000001c0| 72 72 6f 72 20 22 54 68 | 69 73 20 66 69 6c 65 20 |rror "Th|is file |
|000001d0| 77 61 73 20 63 6f 6d 70 | 69 6c 65 64 20 66 6f 72 |was comp|iled for|
|000001e0| 20 45 6d 61 63 73 20 31 | 39 2e 22 29 29 0a 0a 28 | Emacs 1|9."))..(|
|000001f0| 64 65 66 76 61 72 20 68 | 61 73 68 2d 6d 65 72 67 |defvar h|ash-merg|
|00000200| 65 2d 76 61 6c 75 65 73 | 2d 66 75 6e 63 74 69 6f |e-values|-functio|
|00000210| 6e 20 27 68 61 73 68 2d | 6d 65 72 67 65 2d 76 61 |n 'hash-|merge-va|
|00000220| 6c 75 65 73 20 22 5c 0a | 2a 46 75 6e 63 74 69 6f |lues "\.|*Functio|
|00000230| 6e 20 74 6f 20 63 61 6c | 6c 20 69 6e 20 68 61 73 |n to cal|l in has|
|00000240| 68 2d 6d 65 72 67 65 20 | 74 6f 20 6d 65 72 67 65 |h-merge |to merge|
|00000250| 20 74 68 65 20 76 61 6c | 75 65 73 20 66 72 6f 6d | the val|ues from|
|00000260| 20 32 20 68 61 73 68 20 | 74 61 62 6c 65 73 20 74 | 2 hash |tables t|
|00000270| 68 61 74 20 63 6f 6e 74 | 61 69 6e 20 74 68 65 20 |hat cont|ain the |
|00000280| 73 61 6d 65 20 6b 65 79 | 2e 0a 49 74 20 69 73 20 |same key|..It is |
|00000290| 73 65 6e 74 20 74 68 65 | 20 74 77 6f 20 76 61 6c |sent the| two val|
|000002a0| 75 65 73 20 61 73 20 61 | 72 67 75 6d 65 6e 74 73 |ues as a|rguments|
|000002b0| 2e 22 29 0a 28 66 73 65 | 74 20 27 68 61 73 68 2d |.").(fse|t 'hash-|
|000002c0| 61 64 64 20 23 5b 28 76 | 61 6c 75 65 20 6b 65 79 |add #[(v|alue key|
|000002d0| 20 68 61 73 68 2d 74 61 | 62 6c 65 29 20 22 c0 09 | hash-ta|ble) "..|
|000002e0| 21 ad 93 c2 09 21 1b c4 | 0d 0b 5c 22 89 1e 06 ad |!....!..|..\"....|
|000002f0| 85 0e 06 0e 07 4c 2a 87 | 22 20 5b 68 61 73 68 70 |.....L*.|" [hashp|
|00000300| 20 68 61 73 68 2d 74 61 | 62 6c 65 20 68 61 73 68 | hash-ta|ble hash|
|00000310| 2d 6f 62 61 72 72 61 79 | 20 6f 62 61 72 72 61 79 |-obarray| obarray|
|00000320| 20 69 6e 74 65 72 6e 20 | 6b 65 79 20 73 79 6d 20 | intern |key sym |
|00000330| 76 61 6c 75 65 5d 20 34 | 20 22 5c 0a 41 64 64 20 |value] 4| "\.Add |
|00000340| 56 41 4c 55 45 2c 20 61 | 6e 79 20 6c 69 73 70 20 |VALUE, a|ny lisp |
|00000350| 6f 62 6a 65 63 74 2c 20 | 72 65 66 65 72 65 6e 63 |object, |referenc|
|00000360| 65 64 20 62 79 20 4b 45 | 59 2c 20 61 20 73 74 72 |ed by KE|Y, a str|
|00000370| 69 6e 67 2c 20 74 6f 20 | 48 41 53 48 2d 54 41 42 |ing, to |HASH-TAB|
|00000380| 4c 45 2e 0a 52 65 70 6c | 61 63 65 73 20 61 6e 79 |LE..Repl|aces any|
|00000390| 20 56 41 4c 55 45 20 70 | 72 65 76 69 6f 75 73 6c | VALUE p|reviousl|
|000003a0| 79 20 72 65 66 65 72 65 | 6e 63 65 64 20 62 79 20 |y refere|nced by |
|000003b0| 4b 45 59 2e 22 5d 29 0a | 28 66 73 65 74 20 27 68 |KEY."]).|(fset 'h|
|000003c0| 61 73 68 2d 63 6f 70 79 | 20 23 5b 28 68 61 73 68 |ash-copy| #[(hash|
|000003d0| 2d 74 61 62 6c 65 29 20 | 22 c0 09 21 ac 85 c2 c3 |-table) |"..!....|
|000003e0| 09 5c 22 88 c4 c5 09 21 | 47 21 1e 06 c7 c8 09 5c |.\"....!|G!.....\|
|000003f0| 22 88 0e 06 29 87 22 20 | 5b 68 61 73 68 70 20 68 |"...)." |[hashp h|
|00000400| 61 73 68 2d 74 61 62 6c | 65 20 65 72 72 6f 72 20 |ash-tabl|e error |
|00000410| 22 28 68 61 73 68 2d 63 | 6f 70 79 29 3a 20 49 6e |"(hash-c|opy): In|
|00000420| 76 61 6c 69 64 20 68 61 | 73 68 2d 74 61 62 6c 65 |valid ha|sh-table|
|00000430| 3a 20 27 25 73 27 22 20 | 68 61 73 68 2d 6d 61 6b |: '%s'" |hash-mak|
|00000440| 65 20 68 61 73 68 2d 6f | 62 61 72 72 61 79 20 68 |e hash-o|barray h|
|00000450| 74 61 62 6c 65 2d 63 6f | 70 79 20 68 61 73 68 2d |table-co|py hash-|
|00000460| 6d 61 70 20 23 5b 28 65 | 6c 74 29 20 22 c0 09 40 |map #[(e|lt) "..@|
|00000470| 09 41 5c 6e 23 87 22 20 | 5b 68 61 73 68 2d 61 64 |.A\n#." |[hash-ad|
|00000480| 64 20 65 6c 74 20 68 74 | 61 62 6c 65 2d 63 6f 70 |d elt ht|able-cop|
|00000490| 79 5d 20 34 5d 5d 20 33 | 20 22 5c 0a 52 65 74 75 |y] 4]] 3| "\.Retu|
|000004a0| 72 6e 20 61 20 63 6f 70 | 79 20 6f 66 20 48 41 53 |rn a cop|y of HAS|
|000004b0| 48 2d 54 41 42 4c 45 2c | 20 6c 69 73 74 20 61 6e |H-TABLE,| list an|
|000004c0| 64 20 76 65 63 74 6f 72 | 20 65 6c 65 6d 65 6e 74 |d vector| element|
|000004d0| 73 20 61 72 65 20 73 68 | 61 72 65 64 20 61 63 72 |s are sh|ared acr|
|000004e0| 6f 73 73 20 62 6f 74 68 | 20 74 61 62 6c 65 73 2e |oss both| tables.|
|000004f0| 22 5d 29 0a 28 66 73 65 | 74 20 27 68 61 73 68 2d |"]).(fse|t 'hash-|
|00000500| 63 6f 75 6e 74 20 23 5b | 28 68 61 73 68 2d 74 61 |count #[|(hash-ta|
|00000510| 62 6c 65 29 20 22 c0 09 | 21 ad 8d c2 09 21 c3 1c |ble) "..|!....!..|
|00000520| 1d c6 c7 0d 5c 22 88 0c | 2a 87 22 20 5b 68 61 73 |....\"..|*." [has|
|00000530| 68 70 20 68 61 73 68 2d | 74 61 62 6c 65 20 68 61 |hp hash-|table ha|
|00000540| 73 68 2d 6f 62 61 72 72 | 61 79 20 30 20 63 6f 75 |sh-obarr|ay 0 cou|
|00000550| 6e 74 20 6f 62 61 72 72 | 61 79 20 6d 61 70 61 74 |nt obarr|ay mapat|
|00000560| 6f 6d 73 20 23 5b 28 73 | 79 6d 29 20 22 c0 09 21 |oms #[(s|ym) "..!|
|00000570| ad 87 09 ad 84 5c 6e 54 | 89 12 87 22 20 5b 62 6f |.....\nT|..." [bo|
|00000580| 75 6e 64 70 20 73 79 6d | 20 63 6f 75 6e 74 5d 20 |undp sym| count] |
|00000590| 32 5d 5d 20 33 20 22 5c | 0a 52 65 74 75 72 6e 20 |2]] 3 "\|.Return |
|000005a0| 6e 75 6d 62 65 72 20 6f | 66 20 65 6c 65 6d 65 6e |number o|f elemen|
|000005b0| 74 73 20 73 74 6f 72 65 | 64 20 69 6e 20 48 41 53 |ts store|d in HAS|
|000005c0| 48 2d 54 41 42 4c 45 20 | 6f 72 20 6e 69 6c 20 69 |H-TABLE |or nil i|
|000005d0| 66 20 6e 6f 74 20 61 20 | 76 61 6c 69 64 20 68 61 |f not a |valid ha|
|000005e0| 73 68 20 74 61 62 6c 65 | 2e 22 5d 29 0a 28 66 73 |sh table|."]).(fs|
|000005f0| 65 74 20 27 68 61 73 68 | 2d 64 65 6c 65 74 65 20 |et 'hash|-delete |
|00000600| 23 5b 28 6b 65 79 20 68 | 61 73 68 2d 74 61 62 6c |#[(key h|ash-tabl|
|00000610| 65 29 20 22 c0 09 21 ad | 92 c2 09 21 1b c4 0d 0b |e) "..!.|...!....|
|00000620| 5c 22 89 1e 06 ad 84 c7 | 0e 06 21 2a 87 22 20 5b |\"......|..!*." [|
|00000630| 68 61 73 68 70 20 68 61 | 73 68 2d 74 61 62 6c 65 |hashp ha|sh-table|
|00000640| 20 68 61 73 68 2d 6f 62 | 61 72 72 61 79 20 6f 62 | hash-ob|array ob|
|00000650| 61 72 72 61 79 20 69 6e | 74 65 72 6e 2d 73 6f 66 |array in|tern-sof|
|00000660| 74 20 6b 65 79 20 73 79 | 6d 20 6d 61 6b 75 6e 62 |t key sy|m makunb|
|00000670| 6f 75 6e 64 5d 20 34 20 | 22 5c 0a 44 65 6c 65 74 |ound] 4 |"\.Delet|
|00000680| 65 20 65 6c 65 6d 65 6e | 74 20 72 65 66 65 72 65 |e elemen|t refere|
|00000690| 6e 63 65 64 20 62 79 20 | 4b 45 59 2c 20 61 20 73 |nced by |KEY, a s|
|000006a0| 74 72 69 6e 67 2c 20 66 | 72 6f 6d 20 48 41 53 48 |tring, f|rom HASH|
|000006b0| 2d 54 41 42 4c 45 2e 0a | 4e 6f 20 65 72 72 6f 72 |-TABLE..|No error|
|000006c0| 20 77 69 6c 6c 20 6f 63 | 63 75 72 20 69 66 20 4b | will oc|cur if K|
|000006d0| 45 59 20 69 73 20 6e 6f | 74 20 66 6f 75 6e 64 20 |EY is no|t found |
|000006e0| 69 6e 20 48 41 53 48 2d | 54 41 42 4c 45 2e 22 5d |in HASH-|TABLE."]|
|000006f0| 29 0a 28 66 73 65 74 20 | 27 68 61 73 68 2d 64 65 |).(fset |'hash-de|
|00000700| 65 70 2d 63 6f 70 79 20 | 23 5b 28 6f 62 6a 29 20 |ep-copy |#[(obj) |
|00000710| 22 08 ac 82 c1 87 08 3b | ab 84 c2 08 21 87 c3 08 |"......;|....!...|
|00000720| 21 ab 94 c4 c5 08 21 47 | 21 1e 06 c7 c8 c9 ca 08 |!.....!G|!.......|
|00000730| 5c 22 5c 22 88 0e 06 29 | 87 cb 08 21 ab 8c cc 08 |\"\"...)|...!....|
|00000740| c1 5c 22 10 cd c7 ca 08 | 5c 22 21 87 08 3a ac 82 |.\".....|\"!..:..|
|00000750| 08 87 08 3c ac 85 ce cf | 08 5c 22 87 ca 08 40 21 |...<....|.\"...@!|
|00000760| ca 08 41 21 42 87 22 20 | 5b 6f 62 6a 20 6e 69 6c |..A!B." |[obj nil|
|00000770| 20 63 6f 70 79 2d 73 65 | 71 75 65 6e 63 65 20 68 | copy-se|quence h|
|00000780| 61 73 68 70 20 68 61 73 | 68 2d 6d 61 6b 65 20 68 |ashp has|h-make h|
|00000790| 61 73 68 2d 6f 62 61 72 | 72 61 79 20 68 74 61 62 |ash-obar|ray htab|
|000007a0| 6c 65 2d 63 6f 70 79 20 | 6d 61 70 63 61 72 20 23 |le-copy |mapcar #|
|000007b0| 5b 28 65 6c 74 29 20 22 | c0 09 40 09 41 5c 6e 23 |[(elt) "|..@.A\n#|
|000007c0| 87 22 20 5b 68 61 73 68 | 2d 61 64 64 20 65 6c 74 |." [hash|-add elt|
|000007d0| 20 68 74 61 62 6c 65 2d | 63 6f 70 79 5d 20 34 5d | htable-|copy] 4]|
|000007e0| 20 68 61 73 68 2d 6d 61 | 70 20 68 61 73 68 2d 64 | hash-ma|p hash-d|
|000007f0| 65 65 70 2d 63 6f 70 79 | 20 76 65 63 74 6f 72 70 |eep-copy| vectorp|
|00000800| 20 61 70 70 65 6e 64 20 | 76 63 6f 6e 63 61 74 20 | append |vconcat |
|00000810| 65 72 72 6f 72 20 22 28 | 68 61 73 68 2d 64 65 65 |error "(|hash-dee|
|00000820| 70 2d 63 6f 70 79 29 3a | 20 49 6e 76 61 6c 69 64 |p-copy):| Invalid|
|00000830| 20 74 79 70 65 2c 20 27 | 25 73 27 22 5d 20 35 20 | type, '|%s'"] 5 |
|00000840| 22 5c 0a 52 65 74 75 72 | 6e 20 61 20 63 6f 70 79 |"\.Retur|n a copy|
|00000850| 20 6f 66 20 4f 42 4a 20 | 77 69 74 68 20 6e 65 77 | of OBJ |with new|
|00000860| 20 63 6f 70 69 65 73 20 | 6f 66 20 61 6c 6c 20 65 | copies |of all e|
|00000870| 6c 65 6d 65 6e 74 73 2c | 20 65 78 63 65 70 74 20 |lements,| except |
|00000880| 73 79 6d 62 6f 6c 73 2e | 22 5d 29 0a 28 66 73 65 |symbols.|"]).(fse|
|00000890| 74 20 27 68 61 73 68 2d | 67 65 74 20 27 68 61 73 |t 'hash-|get 'has|
|000008a0| 68 2d 6c 6f 6f 6b 75 70 | 29 0a 28 66 73 65 74 20 |h-lookup|).(fset |
|000008b0| 27 68 61 73 68 2d 6b 65 | 79 2d 70 20 23 5b 28 6b |'hash-ke|y-p #[(k|
|000008c0| 65 79 20 68 61 73 68 2d | 74 61 62 6c 65 29 20 22 |ey hash-|table) "|
|000008d0| c0 09 21 ad 93 c2 09 21 | 1b c4 0d 0b 5c 22 1e 06 |..!....!|....\"..|
|000008e0| c7 0e 06 21 ad 82 0e 06 | 2a 87 22 20 5b 68 61 73 |...!....|*." [has|
|000008f0| 68 70 20 68 61 73 68 2d | 74 61 62 6c 65 20 68 61 |hp hash-|table ha|
|00000900| 73 68 2d 6f 62 61 72 72 | 61 79 20 6f 62 61 72 72 |sh-obarr|ay obarr|
|00000910| 61 79 20 69 6e 74 65 72 | 6e 2d 73 6f 66 74 20 6b |ay inter|n-soft k|
|00000920| 65 79 20 73 79 6d 20 62 | 6f 75 6e 64 70 5d 20 33 |ey sym b|oundp] 3|
|00000930| 20 22 5c 0a 52 65 74 75 | 72 6e 20 6e 6f 6e 2d 6e | "\.Retu|rn non-n|
|00000940| 69 6c 20 69 66 66 20 4b | 45 59 20 69 73 20 69 6e |il iff K|EY is in|
|00000950| 20 48 41 53 48 2d 54 41 | 42 4c 45 2e 20 20 4b 45 | HASH-TA|BLE. KE|
|00000960| 59 27 73 20 68 61 73 68 | 20 74 61 62 6c 65 20 73 |Y's hash| table s|
|00000970| 79 6d 62 6f 6c 20 69 73 | 20 72 65 74 75 72 6e 65 |ymbol is| returne|
|00000980| 64 2e 22 5d 29 0a 28 66 | 73 65 74 20 27 68 61 73 |d."]).(f|set 'has|
|00000990| 68 2d 6c 6f 6f 6b 75 70 | 20 23 5b 28 6b 65 79 20 |h-lookup| #[(key |
|000009a0| 68 61 73 68 2d 74 61 62 | 6c 65 29 20 22 c0 09 21 |hash-tab|le) "..!|
|000009b0| ad 94 c2 09 21 1b c4 0d | 0b 5c 22 1e 06 c7 0e 06 |....!...|.\".....|
|000009c0| 21 ad 83 0e 06 4a 2a 87 | 22 20 5b 68 61 73 68 70 |!....J*.|" [hashp|
|000009d0| 20 68 61 73 68 2d 74 61 | 62 6c 65 20 68 61 73 68 | hash-ta|ble hash|
|000009e0| 2d 6f 62 61 72 72 61 79 | 20 6f 62 61 72 72 61 79 |-obarray| obarray|
|000009f0| 20 69 6e 74 65 72 6e 2d | 73 6f 66 74 20 6b 65 79 | intern-|soft key|
|00000a00| 20 73 79 6d 20 62 6f 75 | 6e 64 70 5d 20 33 20 22 | sym bou|ndp] 3 "|
|00000a10| 5c 0a 4c 6f 6f 6b 75 70 | 20 4b 45 59 20 69 6e 20 |\.Lookup| KEY in |
|00000a20| 48 41 53 48 2d 54 41 42 | 4c 45 20 61 6e 64 20 72 |HASH-TAB|LE and r|
|00000a30| 65 74 75 72 6e 20 61 73 | 73 6f 63 69 61 74 65 64 |eturn as|sociated|
|00000a40| 20 76 61 6c 75 65 2e 0a | 49 66 20 76 61 6c 75 65 | value..|If value|
|00000a50| 20 69 73 20 6e 69 6c 2c | 20 74 68 69 73 20 66 75 | is nil,| this fu|
|00000a60| 6e 63 74 69 6f 6e 20 64 | 6f 65 73 20 6e 6f 74 20 |nction d|oes not |
|00000a70| 74 65 6c 6c 20 79 6f 75 | 20 77 68 65 74 68 65 72 |tell you| whether|
|00000a80| 20 6f 72 20 6e 6f 74 20 | 4b 45 59 20 69 73 20 69 | or not |KEY is i|
|00000a90| 6e 20 74 68 65 0a 68 61 | 73 68 20 74 61 62 6c 65 |n the.ha|sh table|
|00000aa0| 2e 20 20 55 73 65 20 27 | 68 61 73 68 2d 6b 65 79 |. Use '|hash-key|
|00000ab0| 2d 70 27 20 69 6e 73 74 | 65 61 64 20 66 6f 72 20 |-p' inst|ead for |
|00000ac0| 74 68 61 74 20 66 75 6e | 63 74 69 6f 6e 2e 22 5d |that fun|ction."]|
|00000ad0| 29 0a 28 66 73 65 74 20 | 27 68 61 73 68 2d 6d 61 |).(fset |'hash-ma|
|00000ae0| 6b 65 20 23 5b 28 69 6e | 69 74 69 61 6c 69 7a 65 |ke #[(in|itialize|
|00000af0| 72 20 26 6f 70 74 69 6f | 6e 61 6c 20 72 65 76 65 |r &optio|nal reve|
|00000b00| 72 73 65 29 20 22 08 a8 | ab 93 08 c1 59 ab 89 c2 |rse) "..|....Y...|
|00000b10| c3 c4 08 21 c1 5c 22 42 | 87 c5 c6 08 5c 22 87 c4 |...!.\"B|....\"..|
|00000b20| 08 47 21 1e 07 c3 0e 07 | c1 5c 22 1e 08 c9 1e 5c |.G!.....|.\"....\|
|00000b30| 6e cb cc 08 5c 22 88 c2 | 0e 08 2b 42 87 22 20 5b |n...\"..|..+B." [|
|00000b40| 69 6e 69 74 69 61 6c 69 | 7a 65 72 20 30 20 68 61 |initiali|zer 0 ha|
|00000b50| 73 68 74 20 6d 61 6b 65 | 2d 76 65 63 74 6f 72 20 |sht make|-vector |
|00000b60| 68 61 73 68 2d 6e 65 78 | 74 2d 70 72 69 6d 65 20 |hash-nex|t-prime |
|00000b70| 65 72 72 6f 72 20 22 28 | 68 61 73 68 2d 6d 61 6b |error "(|hash-mak|
|00000b80| 65 29 3a 20 49 6e 69 74 | 69 61 6c 69 7a 65 72 20 |e): Init|ializer |
|00000b90| 6d 75 73 74 20 62 65 20 | 3e 3d 20 30 2c 20 6e 6f |must be |>= 0, no|
|00000ba0| 74 20 27 25 73 27 22 20 | 76 6c 65 6e 20 6f 62 61 |t '%s'" |vlen oba|
|00000bb0| 72 72 61 79 20 6e 69 6c | 20 73 79 6d 20 6d 61 70 |rray nil| sym map|
|00000bc0| 63 61 72 20 23 5b 28 63 | 6e 73 29 20 22 c0 89 19 |car #[(c|ns) "...|
|00000bd0| 1a 0b 3a ab 91 0c ab 88 | 0b 40 12 0b 41 11 aa 86 |..:.....|.@..A...|
|00000be0| 0b 41 12 0b 40 11 c5 5c | 6e 21 89 16 06 ad 84 0e |.A..@..\|n!......|
|00000bf0| 06 09 4c 2a 87 22 20 5b | 6e 69 6c 20 76 61 6c 75 |..L*." [|nil valu|
|00000c00| 65 20 6b 65 79 20 63 6e | 73 20 72 65 76 65 72 73 |e key cn|s revers|
|00000c10| 65 20 69 6e 74 65 72 6e | 20 73 79 6d 5d 20 32 5d |e intern| sym] 2]|
|00000c20| 5d 20 34 20 22 5c 0a 43 | 72 65 61 74 65 20 61 20 |] 4 "\.C|reate a |
|00000c30| 68 61 73 68 20 74 61 62 | 6c 65 20 66 72 6f 6d 20 |hash tab|le from |
|00000c40| 49 4e 49 54 49 41 4c 49 | 5a 45 52 2e 0a 49 4e 49 |INITIALI|ZER..INI|
|00000c50| 54 49 41 4c 49 5a 45 52 | 20 6d 61 79 20 62 65 20 |TIALIZER| may be |
|00000c60| 61 6e 20 61 6c 69 73 74 | 20 77 69 74 68 20 65 6c |an alist| with el|
|00000c70| 65 6d 65 6e 74 73 20 6f | 66 20 74 68 65 20 66 6f |ements o|f the fo|
|00000c80| 72 6d 20 28 3c 76 61 6c | 75 65 3e 20 2e 20 3c 6b |rm (<val|ue> . <k|
|00000c90| 65 79 3e 29 20 66 72 6f | 6d 0a 77 68 69 63 68 20 |ey>) fro|m.which |
|00000ca0| 74 68 65 20 68 61 73 68 | 20 74 61 62 6c 65 20 69 |the hash| table i|
|00000cb0| 73 20 62 75 69 6c 74 2e | 20 20 41 6c 74 65 72 6e |s built.| Altern|
|00000cc0| 61 74 69 76 65 6c 79 2c | 20 69 74 20 6d 61 79 20 |atively,| it may |
|00000cd0| 62 65 20 61 20 6e 6f 6e | 2d 6e 65 67 61 74 69 76 |be a non|-negativ|
|00000ce0| 65 0a 69 6e 74 65 67 65 | 72 20 77 68 69 63 68 20 |e.intege|r which |
|00000cf0| 69 73 20 75 73 65 64 20 | 61 73 20 74 68 65 20 6d |is used |as the m|
|00000d00| 69 6e 69 6d 75 6d 20 73 | 69 7a 65 20 6f 66 20 61 |inimum s|ize of a|
|00000d10| 20 6e 65 77 2c 20 65 6d | 70 74 79 20 68 61 73 68 | new, em|pty hash|
|00000d20| 20 74 61 62 6c 65 2e 0a | 4f 70 74 69 6f 6e 61 6c | table..|Optional|
|00000d30| 20 6e 6f 6e 2d 6e 69 6c | 20 73 65 63 6f 6e 64 20 | non-nil| second |
|00000d40| 61 72 67 75 6d 65 6e 74 | 20 52 45 56 45 52 53 45 |argument| REVERSE|
|00000d50| 20 6d 65 61 6e 73 20 49 | 4e 49 54 49 41 4c 49 5a | means I|NITIALIZ|
|00000d60| 45 52 20 68 61 73 20 65 | 6c 65 6d 65 6e 74 73 20 |ER has e|lements |
|00000d70| 6f 66 0a 66 6f 72 6d 20 | 28 3c 6b 65 79 3e 20 2e |of.form |(<key> .|
|00000d80| 20 3c 76 61 6c 75 65 3e | 29 2e 22 5d 29 0a 28 66 | <value>|)."]).(f|
|00000d90| 73 65 74 20 27 68 61 73 | 68 2d 6d 61 70 20 23 5b |set 'has|h-map #[|
|00000da0| 28 66 75 6e 63 20 68 61 | 73 68 2d 74 61 62 6c 65 |(func ha|sh-table|
|00000db0| 29 20 22 c0 09 21 ac 85 | c2 c3 09 5c 22 88 c4 1d |) "..!..|...\"...|
|00000dc0| c6 c7 c8 09 21 5c 22 88 | 0d 29 87 22 20 5b 68 61 |....!\".|.)." [ha|
|00000dd0| 73 68 70 20 68 61 73 68 | 2d 74 61 62 6c 65 20 65 |shp hash|-table e|
|00000de0| 72 72 6f 72 20 22 28 68 | 61 73 68 2d 6d 61 70 29 |rror "(h|ash-map)|
|00000df0| 3a 20 49 6e 76 61 6c 69 | 64 20 68 61 73 68 2d 74 |: Invali|d hash-t|
|00000e00| 61 62 6c 65 3a 20 27 25 | 73 27 22 20 6e 69 6c 20 |able: '%|s'" nil |
|00000e10| 72 65 73 75 6c 74 20 6d | 61 70 61 74 6f 6d 73 20 |result m|apatoms |
|00000e20| 23 5b 28 73 79 6d 29 20 | 22 c0 09 21 ad 8f 09 ad |#[(sym) |"..!....|
|00000e30| 8c 5c 6e 09 4a c3 09 21 | 42 21 0c 42 89 14 87 22 |.\n.J..!|B!.B..."|
|00000e40| 20 5b 62 6f 75 6e 64 70 | 20 73 79 6d 20 66 75 6e | [boundp| sym fun|
|00000e50| 63 20 73 79 6d 62 6f 6c | 2d 6e 61 6d 65 20 72 65 |c symbol|-name re|
|00000e60| 73 75 6c 74 5d 20 34 5d | 20 68 61 73 68 2d 6f 62 |sult] 4]| hash-ob|
|00000e70| 61 72 72 61 79 5d 20 34 | 20 22 5c 0a 52 65 74 75 |array] 4| "\.Retu|
|00000e80| 72 6e 20 72 65 73 75 6c | 74 20 6f 66 20 61 70 70 |rn resul|t of app|
|00000e90| 6c 69 63 61 74 69 6f 6e | 20 6f 66 20 46 55 4e 43 |lication| of FUNC|
|00000ea0| 20 74 6f 20 65 61 63 68 | 20 28 3c 76 61 6c 75 65 | to each| (<value|
|00000eb0| 3e 20 2e 20 3c 6b 65 79 | 3e 29 20 65 6c 65 6d 65 |> . <key|>) eleme|
|00000ec0| 6e 74 20 6f 66 20 48 41 | 53 48 2d 54 41 42 4c 45 |nt of HA|SH-TABLE|
|00000ed0| 2e 22 5d 29 0a 28 66 73 | 65 74 20 27 68 61 73 68 |."]).(fs|et 'hash|
|00000ee0| 2d 6d 65 72 67 65 20 23 | 5b 28 26 72 65 73 74 20 |-merge #|[(&rest |
|00000ef0| 68 61 73 68 2d 74 61 62 | 6c 65 73 29 20 22 c0 c1 |hash-tab|les) "..|
|00000f00| 21 1a c3 0c 40 21 ac 88 | 0c 40 3c ab 83 0c 40 14 |!...@!..|.@<...@.|
|00000f10| c5 c6 c7 0c 5c 22 3e ab | 83 5c 6e aa b8 c8 c5 c6 |....\">.|.\n.....|
|00000f20| c9 0c 5c 22 5c 22 89 14 | 47 89 1e 5c 6e cb 55 ab |..\"\"..|G..\n.U.|
|00000f30| 83 5c 6e aa a3 0e 5c 6e | c1 55 ab 84 0c 40 aa 99 |.\n...\n|.U...@..|
|00000f40| c0 cc cd c6 ce 0c 5c 22 | 5c 22 21 c5 89 1e 0f 1e |......\"|\"!.....|
|00000f50| 10 1e 11 c6 d2 0c 5c 22 | 88 0e 11 2b 29 29 87 22 |......\"|...+))."|
|00000f60| 20 5b 68 61 73 68 2d 6d | 61 6b 65 20 31 20 65 6d | [hash-m|ake 1 em|
|00000f70| 70 74 79 2d 68 74 20 68 | 61 73 68 70 20 68 61 73 |pty-ht h|ashp has|
|00000f80| 68 2d 74 61 62 6c 65 73 | 20 6e 69 6c 20 6d 61 70 |h-tables| nil map|
|00000f90| 63 61 72 20 23 5b 28 68 | 74 29 20 22 08 3f ae 83 |car #[(h|t) ".?..|
|00000fa0| c1 08 21 87 22 20 5b 68 | 74 20 68 61 73 68 70 5d |..!." [h|t hashp]|
|00000fb0| 20 32 5d 20 64 65 6c 71 | 20 23 5b 28 68 74 29 20 | 2] delq| #[(ht) |
|00000fc0| 22 08 09 9a 3f ad 81 08 | 87 22 20 5b 68 74 20 65 |"...?...|." [ht e|
|00000fd0| 6d 70 74 79 2d 68 74 5d | 20 32 5d 20 6c 65 6e 20 |mpty-ht]| 2] len |
|00000fe0| 30 20 61 70 70 6c 79 20 | 2b 20 68 61 73 68 2d 63 |0 apply |+ hash-c|
|00000ff0| 6f 75 6e 74 20 76 61 6c | 75 65 20 6b 65 79 20 68 |ount val|ue key h|
|00001000| 74 61 62 6c 65 20 23 5b | 28 68 74 29 20 22 c0 c1 |table #[|(ht) "..|
|00001010| 5c 6e 5c 22 87 22 20 5b | 68 61 73 68 2d 6d 61 70 |\n\"." [|hash-map|
|00001020| 20 23 5b 28 76 61 6c 2d | 6b 65 79 2d 63 6f 6e 73 | #[(val-|key-cons|
|00001030| 29 20 22 08 40 11 08 41 | 12 c3 5c 6e 0c 5c 22 ac |) ".@..A|..\n.\".|
|00001040| 86 c5 09 5c 6e 0c 23 87 | c5 0e 06 c7 5c 6e 0c 5c |...\n.#.|....\n.\|
|00001050| 22 09 5c 22 5c 6e 0c 23 | 87 22 20 5b 76 61 6c 2d |".\"\n.#|." [val-|
|00001060| 6b 65 79 2d 63 6f 6e 73 | 20 76 61 6c 75 65 20 6b |key-cons| value k|
|00001070| 65 79 20 68 61 73 68 2d | 6b 65 79 2d 70 20 68 74 |ey hash-|key-p ht|
|00001080| 61 62 6c 65 20 68 61 73 | 68 2d 61 64 64 20 68 61 |able has|h-add ha|
|00001090| 73 68 2d 6d 65 72 67 65 | 2d 76 61 6c 75 65 73 2d |sh-merge|-values-|
|000010a0| 66 75 6e 63 74 69 6f 6e | 20 68 61 73 68 2d 67 65 |function| hash-ge|
|000010b0| 74 5d 20 35 5d 20 68 74 | 5d 20 33 5d 5d 20 37 20 |t] 5] ht|] 3]] 7 |
|000010c0| 22 5c 0a 4d 65 72 67 65 | 20 61 6e 79 20 6e 75 6d |"\.Merge| any num|
|000010d0| 62 65 72 20 6f 66 20 48 | 41 53 48 2d 54 41 42 4c |ber of H|ASH-TABL|
|000010e0| 45 53 2e 20 20 52 65 74 | 75 72 6e 20 72 65 73 75 |ES. Ret|urn resu|
|000010f0| 6c 74 61 6e 74 20 68 61 | 73 68 20 74 61 62 6c 65 |ltant ha|sh table|
|00001100| 2e 0a 41 20 73 69 6e 67 | 6c 65 20 61 72 67 75 6d |..A sing|le argum|
|00001110| 65 6e 74 20 63 6f 6e 73 | 69 73 74 69 6e 67 20 6f |ent cons|isting o|
|00001120| 66 20 61 20 6c 69 73 74 | 20 6f 66 20 68 61 73 68 |f a list| of hash|
|00001130| 20 74 61 62 6c 65 73 20 | 6d 61 79 20 61 6c 73 6f | tables |may also|
|00001140| 20 62 65 20 67 69 76 65 | 6e 2e 0a 52 65 74 75 72 | be give|n..Retur|
|00001150| 6e 20 61 6e 20 65 6d 70 | 74 79 20 68 61 73 68 20 |n an emp|ty hash |
|00001160| 74 61 62 6c 65 20 69 66 | 20 61 6e 79 20 61 72 67 |table if| any arg|
|00001170| 75 6d 65 6e 74 20 66 72 | 6f 6d 20 74 68 65 20 6d |ument fr|om the m|
|00001180| 65 72 67 65 20 6c 69 73 | 74 20 69 73 20 6f 74 68 |erge lis|t is oth|
|00001190| 65 72 0a 74 68 61 6e 20 | 6e 69 6c 20 6f 72 20 61 |er.than |nil or a|
|000011a0| 20 68 61 73 68 20 74 61 | 62 6c 65 2e 22 5d 29 0a | hash ta|ble."]).|
|000011b0| 28 66 73 65 74 20 27 68 | 61 73 68 2d 6d 65 72 67 |(fset 'h|ash-merg|
|000011c0| 65 2d 76 61 6c 75 65 73 | 20 23 5b 28 76 61 6c 75 |e-values| #[(valu|
|000011d0| 65 31 20 76 61 6c 75 65 | 32 29 20 22 08 3c ab 8e |e1 value|2) ".<..|
|000011e0| 09 3c ab 8a c2 c3 c4 08 | 09 5c 22 c5 5c 22 21 87 |.<......|.\".\"!.|
|000011f0| 08 ac 82 09 87 09 ac 82 | 08 87 08 3c ab 84 09 08 |........|...<....|
|00001200| 42 87 09 3c ab 84 08 09 | 42 87 08 09 44 87 22 20 |B..<....|B...D." |
|00001210| 5b 76 61 6c 75 65 31 20 | 76 61 6c 75 65 32 20 62 |[value1 |value2 b|
|00001220| 72 2d 73 65 74 2d 6f 66 | 2d 73 74 72 69 6e 67 73 |r-set-of|-strings|
|00001230| 20 73 6f 72 74 20 61 70 | 70 65 6e 64 20 73 74 72 | sort ap|pend str|
|00001240| 69 6e 67 3c 5d 20 35 20 | 22 5c 0a 52 65 74 75 72 |ing<] 5 |"\.Retur|
|00001250| 6e 20 61 20 6c 69 73 74 | 20 66 72 6f 6d 20 6d 65 |n a list| from me|
|00001260| 72 67 69 6e 67 20 56 41 | 4c 55 45 31 20 61 6e 64 |rging VA|LUE1 and|
|00001270| 20 56 41 4c 55 45 32 20 | 6f 72 20 63 72 65 61 74 | VALUE2 |or creat|
|00001280| 69 6e 67 20 61 20 6e 65 | 77 20 6c 69 73 74 2e 0a |ing a ne|w list..|
|00001290| 4e 69 6c 20 76 61 6c 75 | 65 73 20 61 72 65 20 74 |Nil valu|es are t|
|000012a0| 68 72 6f 77 6e 20 61 77 | 61 79 2e 20 20 49 66 20 |hrown aw|ay. If |
|000012b0| 62 6f 74 68 20 61 72 67 | 75 6d 65 6e 74 73 20 61 |both arg|uments a|
|000012c0| 72 65 20 6c 69 73 74 73 | 2c 20 74 68 65 69 72 20 |re lists|, their |
|000012d0| 65 6c 65 6d 65 6e 74 73 | 20 61 72 65 0a 61 73 73 |elements| are.ass|
|000012e0| 75 6d 65 64 20 74 6f 20 | 62 65 20 73 74 72 69 6e |umed to |be strin|
|000012f0| 67 73 20 61 6e 64 20 74 | 68 65 20 72 65 73 75 6c |gs and t|he resul|
|00001300| 74 20 69 73 20 61 20 73 | 65 74 20 6f 66 20 6f 72 |t is a s|et of or|
|00001310| 64 65 72 65 64 20 73 74 | 72 69 6e 67 73 2e 22 5d |dered st|rings."]|
|00001320| 29 0a 28 6d 61 6b 65 2d | 6f 62 73 6f 6c 65 74 65 |).(make-|obsolete|
|00001330| 20 27 68 61 73 68 2d 6e | 65 77 20 27 68 61 73 68 | 'hash-n|ew 'hash|
|00001340| 2d 6d 61 6b 65 29 0a 28 | 66 73 65 74 20 27 68 61 |-make).(|fset 'ha|
|00001350| 73 68 2d 6e 65 77 20 23 | 5b 28 73 69 7a 65 29 20 |sh-new #|[(size) |
|00001360| 22 c0 09 21 87 22 20 5b | 68 61 73 68 2d 6d 61 6b |"..!." [|hash-mak|
|00001370| 65 20 73 69 7a 65 5d 20 | 32 20 22 5c 0a 52 65 74 |e size] |2 "\.Ret|
|00001380| 75 72 6e 20 61 20 6e 65 | 77 20 68 61 73 68 20 74 |urn a ne|w hash t|
|00001390| 61 62 6c 65 20 6f 66 20 | 53 49 5a 45 20 65 6c 65 |able of |SIZE ele|
|000013a0| 6d 65 6e 74 73 2e 0a 54 | 68 69 73 20 69 73 20 6f |ments..T|his is o|
|000013b0| 62 73 6f 6c 65 74 65 2e | 20 20 55 73 65 20 27 68 |bsolete.| Use 'h|
|000013c0| 61 73 68 2d 6d 61 6b 65 | 27 20 69 6e 73 74 65 61 |ash-make|' instea|
|000013d0| 64 2e 22 5d 29 0a 28 66 | 73 65 74 20 27 68 61 73 |d."]).(f|set 'has|
|000013e0| 68 2d 70 72 69 6e 31 20 | 23 5b 28 68 61 73 68 2d |h-prin1 |#[(hash-|
|000013f0| 74 61 62 6c 65 20 26 6f | 70 74 69 6f 6e 61 6c 20 |table &o|ptional |
|00001400| 73 74 72 65 61 6d 29 20 | 22 c0 09 21 ac 8a c2 09 |stream) |"..!....|
|00001410| 0b 5c 22 88 c4 c5 0b 5c | 22 87 c4 c6 0b 5c 22 88 |.\"....\|"....\".|
|00001420| c7 c8 09 5c 22 88 c4 c9 | 0b 5c 22 87 22 20 5b 68 |...\"...|.\"." [h|
|00001430| 61 73 68 70 20 68 61 73 | 68 2d 74 61 62 6c 65 20 |ashp has|h-table |
|00001440| 70 72 69 6e 31 20 73 74 | 72 65 61 6d 20 70 72 69 |prin1 st|ream pri|
|00001450| 6e 63 20 22 5c 6e 22 20 | 22 28 5c 6e 22 20 68 61 |nc "\n" |"(\n" ha|
|00001460| 73 68 2d 6d 61 70 20 23 | 5b 28 76 61 6c 2d 6b 65 |sh-map #|[(val-ke|
|00001470| 79 2d 63 6f 6e 73 29 20 | 22 c0 09 5c 6e 5c 22 88 |y-cons) |"..\n\".|
|00001480| c3 c4 5c 6e 5c 22 87 22 | 20 5b 70 72 69 6e 31 20 |..\n\"."| [prin1 |
|00001490| 76 61 6c 2d 6b 65 79 2d | 63 6f 6e 73 20 73 74 72 |val-key-|cons str|
|000014a0| 65 61 6d 20 70 72 69 6e | 63 20 22 5c 6e 22 5d 20 |eam prin|c "\n"] |
|000014b0| 33 5d 20 22 29 5c 6e 22 | 5d 20 33 20 22 5c 0a 4f |3] ")\n"|] 3 "\.O|
|000014c0| 75 74 70 75 74 20 74 68 | 65 20 70 72 69 6e 74 65 |utput th|e printe|
|000014d0| 64 20 72 65 70 72 65 73 | 65 6e 74 61 74 69 6f 6e |d repres|entation|
|000014e0| 20 6f 66 20 48 41 53 48 | 2d 54 41 42 4c 45 2e 0a | of HASH|-TABLE..|
|000014f0| 51 75 6f 74 69 6e 67 20 | 63 68 61 72 61 63 74 65 |Quoting |characte|
|00001500| 72 73 20 61 72 65 20 70 | 72 69 6e 74 65 64 20 77 |rs are p|rinted w|
|00001510| 68 65 6e 20 6e 65 65 64 | 65 64 20 74 6f 20 6d 61 |hen need|ed to ma|
|00001520| 6b 65 20 6f 75 74 70 75 | 74 20 74 68 61 74 20 60 |ke outpu|t that `|
|00001530| 72 65 61 64 27 0a 63 61 | 6e 20 68 61 6e 64 6c 65 |read'.ca|n handle|
|00001540| 2c 20 77 68 65 6e 65 76 | 65 72 20 74 68 69 73 20 |, whenev|er this |
|00001550| 69 73 20 70 6f 73 73 69 | 62 6c 65 2e 0a 4f 75 74 |is possi|ble..Out|
|00001560| 70 75 74 20 73 74 72 65 | 61 6d 20 69 73 20 53 54 |put stre|am is ST|
|00001570| 52 45 41 4d 2c 20 6f 72 | 20 76 61 6c 75 65 20 6f |REAM, or| value o|
|00001580| 66 20 60 73 74 61 6e 64 | 61 72 64 2d 6f 75 74 70 |f `stand|ard-outp|
|00001590| 75 74 27 2e 22 5d 29 0a | 28 66 73 65 74 20 27 68 |ut'."]).|(fset 'h|
|000015a0| 61 73 68 2d 72 65 70 6c | 61 63 65 20 23 5b 28 76 |ash-repl|ace #[(v|
|000015b0| 61 6c 75 65 20 6b 65 79 | 20 68 61 73 68 2d 74 61 |alue key| hash-ta|
|000015c0| 62 6c 65 29 20 22 c0 09 | 21 ad a0 c2 09 21 1b c4 |ble) "..|!....!..|
|000015d0| 0d 0b 5c 22 1e 06 c7 0e | 06 21 ab 8b 0e 06 ab 87 |..\"....|.!......|
|000015e0| 0e 06 0e 08 4c aa 84 c9 | ca 0d 5c 22 2a 87 22 20 |....L...|..\"*." |
|000015f0| 5b 68 61 73 68 70 20 68 | 61 73 68 2d 74 61 62 6c |[hashp h|ash-tabl|
|00001600| 65 20 68 61 73 68 2d 6f | 62 61 72 72 61 79 20 6f |e hash-o|barray o|
|00001610| 62 61 72 72 61 79 20 69 | 6e 74 65 72 6e 2d 73 6f |barray i|ntern-so|
|00001620| 66 74 20 6b 65 79 20 73 | 79 6d 20 62 6f 75 6e 64 |ft key s|ym bound|
|00001630| 70 20 76 61 6c 75 65 20 | 65 72 72 6f 72 20 22 28 |p value |error "(|
|00001640| 68 61 73 68 2d 72 65 70 | 6c 61 63 65 29 3a 20 27 |hash-rep|lace): '|
|00001650| 25 73 27 20 6b 65 79 20 | 6e 6f 74 20 66 6f 75 6e |%s' key |not foun|
|00001660| 64 20 69 6e 20 68 61 73 | 68 20 74 61 62 6c 65 2e |d in has|h table.|
|00001670| 22 5d 20 33 20 22 5c 0a | 52 65 70 6c 61 63 65 20 |"] 3 "\.|Replace |
|00001680| 56 41 4c 55 45 20 72 65 | 66 65 72 65 6e 63 65 64 |VALUE re|ferenced|
|00001690| 20 62 79 20 4b 45 59 2c | 20 61 20 73 74 72 69 6e | by KEY,| a strin|
|000016a0| 67 2c 20 69 6e 20 48 41 | 53 48 2d 54 41 42 4c 45 |g, in HA|SH-TABLE|
|000016b0| 2e 0a 41 6e 20 65 72 72 | 6f 72 20 77 69 6c 6c 20 |..An err|or will |
|000016c0| 6f 63 63 75 72 20 69 66 | 20 4b 45 59 20 69 73 20 |occur if| KEY is |
|000016d0| 6e 6f 74 20 66 6f 75 6e | 64 20 69 6e 20 48 41 53 |not foun|d in HAS|
|000016e0| 48 2d 54 41 42 4c 45 2e | 22 5d 29 0a 28 66 73 65 |H-TABLE.|"]).(fse|
|000016f0| 74 20 27 68 61 73 68 2d | 72 65 73 69 7a 65 20 23 |t 'hash-|resize #|
|00001700| 5b 28 68 61 73 68 2d 74 | 61 62 6c 65 20 6e 65 77 |[(hash-t|able new|
|00001710| 2d 73 69 7a 65 29 20 22 | 08 c1 57 ab 85 c2 c3 08 |-size) "|..W.....|
|00001720| 5c 22 88 c4 08 21 1d c6 | c7 0e 08 5c 22 88 0d 29 |\"...!..|...\"..)|
|00001730| 87 22 20 5b 6e 65 77 2d | 73 69 7a 65 20 31 20 65 |." [new-|size 1 e|
|00001740| 72 72 6f 72 20 22 28 68 | 61 73 68 2d 72 65 73 69 |rror "(h|ash-resi|
|00001750| 7a 65 29 3a 20 43 61 6e | 6e 6f 74 20 72 65 73 69 |ze): Can|not resi|
|00001760| 7a 65 20 68 61 73 68 20 | 74 61 62 6c 65 20 74 6f |ze hash |table to|
|00001770| 20 73 69 7a 65 20 25 64 | 22 20 68 61 73 68 2d 6d | size %d|" hash-m|
|00001780| 61 6b 65 20 68 74 61 62 | 6c 65 20 68 61 73 68 2d |ake htab|le hash-|
|00001790| 6d 61 70 20 23 5b 28 65 | 6c 74 29 20 22 c0 09 40 |map #[(e|lt) "..@|
|000017a0| 09 41 5c 6e 23 87 22 20 | 5b 68 61 73 68 2d 61 64 |.A\n#." |[hash-ad|
|000017b0| 64 20 65 6c 74 20 68 74 | 61 62 6c 65 5d 20 34 5d |d elt ht|able] 4]|
|000017c0| 20 68 61 73 68 2d 74 61 | 62 6c 65 5d 20 33 20 22 | hash-ta|ble] 3 "|
|000017d0| 5c 0a 52 65 73 69 7a 65 | 20 48 41 53 48 2d 54 41 |\.Resize| HASH-TA|
|000017e0| 42 4c 45 20 74 6f 20 4e | 45 57 2d 53 49 5a 45 20 |BLE to N|EW-SIZE |
|000017f0| 77 69 74 68 6f 75 74 20 | 6c 6f 73 69 6e 67 20 61 |without |losing a|
|00001800| 6e 79 20 65 6c 65 6d 65 | 6e 74 73 20 61 6e 64 20 |ny eleme|nts and |
|00001810| 72 65 74 75 72 6e 20 6e | 65 77 20 74 61 62 6c 65 |return n|ew table|
|00001820| 2e 0a 4e 45 57 2d 53 49 | 5a 45 20 6d 75 73 74 20 |..NEW-SI|ZE must |
|00001830| 62 65 20 67 72 65 61 74 | 65 72 20 74 68 61 6e 20 |be great|er than |
|00001840| 30 2e 20 20 48 61 73 68 | 69 6e 67 20 77 6f 72 6b |0. Hash|ing work|
|00001850| 73 20 62 65 73 74 20 69 | 66 20 4e 45 57 2d 53 49 |s best i|f NEW-SI|
|00001860| 5a 45 20 69 73 20 61 20 | 70 72 69 6d 65 0a 6e 75 |ZE is a |prime.nu|
|00001870| 6d 62 65 72 2e 20 20 53 | 65 65 20 61 6c 73 6f 20 |mber. S|ee also |
|00001880| 27 68 61 73 68 2d 6e 65 | 78 74 2d 70 72 69 6d 65 |'hash-ne|xt-prime|
|00001890| 27 2e 22 5d 29 0a 28 66 | 73 65 74 20 27 68 61 73 |'."]).(f|set 'has|
|000018a0| 68 2d 72 65 73 69 7a 65 | 2d 70 20 23 5b 28 68 61 |h-resize|-p #[(ha|
|000018b0| 73 68 2d 74 61 62 6c 65 | 29 20 22 c0 09 21 ad 9d |sh-table|) "..!..|
|000018c0| c2 09 21 c3 09 21 47 1c | 89 1d 89 c6 a5 5f 0c 56 |..!..!G.|....._.V|
|000018d0| ad 8a c7 09 c8 0c 89 c9 | a5 5c 5c 21 5c 22 2a 87 |........|.\\!\"*.|
|000018e0| 22 20 5b 68 61 73 68 70 | 20 68 61 73 68 2d 74 61 |" [hashp| hash-ta|
|000018f0| 62 6c 65 20 68 61 73 68 | 2d 63 6f 75 6e 74 20 68 |ble hash|-count h|
|00001900| 61 73 68 2d 6f 62 61 72 | 72 61 79 20 73 69 7a 65 |ash-obar|ray size|
|00001910| 20 63 6f 75 6e 74 20 35 | 20 68 61 73 68 2d 72 65 | count 5| hash-re|
|00001920| 73 69 7a 65 20 68 61 73 | 68 2d 6e 65 78 74 2d 70 |size has|h-next-p|
|00001930| 72 69 6d 65 20 32 5d 20 | 37 20 22 5c 0a 52 65 73 |rime 2] |7 "\.Res|
|00001940| 69 7a 65 73 20 48 41 53 | 48 2d 54 41 42 4c 45 20 |izes HAS|H-TABLE |
|00001950| 74 6f 20 31 2e 35 20 74 | 69 6d 65 73 20 69 74 73 |to 1.5 t|imes its|
|00001960| 20 73 69 7a 65 20 69 66 | 20 61 62 6f 76 65 20 38 | size if| above 8|
|00001970| 30 25 20 66 75 6c 6c 2e | 0a 52 65 74 75 72 6e 73 |0% full.|.Returns|
|00001980| 20 6e 65 77 20 68 61 73 | 68 20 74 61 62 6c 65 20 | new has|h table |
|00001990| 77 68 65 6e 20 72 65 73 | 69 7a 65 64 2c 20 65 6c |when res|ized, el|
|000019a0| 73 65 20 6e 69 6c 2e 22 | 5d 29 0a 28 66 73 65 74 |se nil."|]).(fset|
|000019b0| 20 27 68 61 73 68 2d 73 | 69 7a 65 20 23 5b 28 68 | 'hash-s|ize #[(h|
|000019c0| 61 73 68 2d 74 61 62 6c | 65 29 20 22 c0 09 21 ad |ash-tabl|e) "..!.|
|000019d0| 84 c2 09 21 47 87 22 20 | 5b 68 61 73 68 70 20 68 |...!G." |[hashp h|
|000019e0| 61 73 68 2d 74 61 62 6c | 65 20 68 61 73 68 2d 6f |ash-tabl|e hash-o|
|000019f0| 62 61 72 72 61 79 5d 20 | 32 20 22 5c 0a 52 65 74 |barray] |2 "\.Ret|
|00001a00| 75 72 6e 20 73 69 7a 65 | 20 6f 66 20 48 41 53 48 |urn size| of HASH|
|00001a10| 2d 54 41 42 4c 45 20 77 | 68 69 63 68 20 69 73 20 |-TABLE w|hich is |
|00001a20| 3e 3d 20 6e 75 6d 62 65 | 72 20 6f 66 20 65 6c 65 |>= numbe|r of ele|
|00001a30| 6d 65 6e 74 73 20 69 6e | 20 74 68 65 20 74 61 62 |ments in| the tab|
|00001a40| 6c 65 2e 0a 52 65 74 75 | 72 6e 20 6e 69 6c 20 69 |le..Retu|rn nil i|
|00001a50| 66 20 6e 6f 74 20 61 20 | 76 61 6c 69 64 20 68 61 |f not a |valid ha|
|00001a60| 73 68 20 74 61 62 6c 65 | 2e 22 5d 29 0a 28 66 73 |sh table|."]).(fs|
|00001a70| 65 74 20 27 68 61 73 68 | 2d 6c 65 6e 67 74 68 20 |et 'hash|-length |
|00001a80| 27 68 61 73 68 2d 73 69 | 7a 65 29 0a 28 66 73 65 |'hash-si|ze).(fse|
|00001a90| 74 20 27 68 61 73 68 70 | 20 23 5b 28 6f 62 6a 65 |t 'hashp| #[(obje|
|00001aa0| 63 74 29 20 22 08 3c ad | 8a 08 40 c1 3d ad 84 c2 |ct) ".<.|..@.=...|
|00001ab0| 08 41 21 87 22 20 5b 6f | 62 6a 65 63 74 20 68 61 |.A!." [o|bject ha|
|00001ac0| 73 68 74 20 76 65 63 74 | 6f 72 70 5d 20 32 20 22 |sht vect|orp] 2 "|
|00001ad0| 5c 0a 52 65 74 75 72 6e | 20 6e 6f 6e 2d 6e 69 6c |\.Return| non-nil|
|00001ae0| 20 69 66 20 4f 42 4a 45 | 43 54 20 69 73 20 61 20 | if OBJE|CT is a |
|00001af0| 68 61 73 68 2d 74 61 62 | 6c 65 2e 22 5d 29 0a 28 |hash-tab|le."]).(|
|00001b00| 66 73 65 74 20 27 68 61 | 73 68 2d 6e 65 78 74 2d |fset 'ha|sh-next-|
|00001b10| 70 72 69 6d 65 20 23 5b | 28 6e 29 20 22 08 c1 58 |prime #[|(n) "..X|
|00001b20| ab 82 c1 87 08 c1 a6 c2 | 55 ab 83 08 54 10 c3 08 |........|U...T...|
|00001b30| 21 ac 86 08 c1 5c 5c 10 | aa 75 08 87 22 20 5b 6e |!....\\.|.u.." [n|
|00001b40| 20 32 20 30 20 68 61 73 | 68 2d 70 72 69 6d 65 2d | 2 0 has|h-prime-|
|00001b50| 70 5d 20 32 20 22 5c 0a | 52 65 74 75 72 6e 20 6e |p] 2 "\.|Return n|
|00001b60| 65 78 74 20 70 72 69 6d | 65 20 6e 75 6d 62 65 72 |ext prim|e number|
|00001b70| 20 3e 3d 20 4e 2e 22 5d | 29 0a 28 66 73 65 74 20 | >= N."]|).(fset |
|00001b80| 27 68 61 73 68 2d 6f 62 | 61 72 72 61 79 20 23 5b |'hash-ob|array #[|
|00001b90| 28 68 61 73 68 2d 74 61 | 62 6c 65 29 20 22 08 41 |(hash-ta|ble) ".A|
|00001ba0| 87 22 20 5b 68 61 73 68 | 2d 74 61 62 6c 65 5d 20 |." [hash|-table] |
|00001bb0| 31 20 22 5c 0a 52 65 74 | 75 72 6e 20 73 79 6d 62 |1 "\.Ret|urn symb|
|00001bc0| 6f 6c 20 74 61 62 6c 65 | 20 28 6f 62 6a 65 63 74 |ol table| (object|
|00001bd0| 20 61 72 72 61 79 29 20 | 70 6f 72 74 69 6f 6e 20 | array) |portion |
|00001be0| 6f 66 20 48 41 53 48 2d | 54 41 42 4c 45 2e 22 5d |of HASH-|TABLE."]|
|00001bf0| 29 0a 28 66 73 65 74 20 | 27 68 61 73 68 2d 70 72 |).(fset |'hash-pr|
|00001c00| 69 6d 65 2d 70 20 23 5b | 28 6e 29 20 22 08 c1 57 |ime-p #[|(n) "..W|
|00001c10| ab 83 08 5b 10 c2 1b 08 | c4 57 ab 85 08 0b 3e aa |...[....|.W....>.|
|00001c20| ed 08 c5 57 ab a0 c6 0b | 1e 07 1e 08 0e 07 41 89 |...W....|......A.|
|00001c30| 16 07 ab 8d 08 0e 07 40 | a6 c1 55 3f 89 16 08 ac |.......@|..U?....|
|00001c40| 6b 0e 08 2a aa c8 08 c9 | a6 c1 55 ac 87 08 ca a6 |k..*....|..U.....|
|00001c50| c1 55 ab 83 cb aa b7 cc | cd cb 1e 0e 1e 0f 1e 10 |.U......|........|
|00001c60| 0e 10 89 5f 08 58 ab a3 | 08 0e 10 a6 c1 55 3f ad |..._.X..|.....U?.|
|00001c70| 87 08 0e 0f a6 c1 55 3f | 89 16 0e ab 8e 0e 10 d1 |......U?|........|
|00001c80| 5c 5c 16 10 0e 0f d1 5c | 5c 16 0f aa 55 0e 0e 2b |\\.....\|\...U..+|
|00001c90| 29 87 22 20 5b 6e 20 30 | 20 28 31 20 32 20 33 20 |)." [n 0| (1 2 3 |
|00001ca0| 35 20 37 20 31 31 20 31 | 33 20 31 37 20 31 39 20 |5 7 11 1|3 17 19 |
|00001cb0| 32 33 20 32 39 20 33 31 | 20 33 37 20 34 31 20 34 |23 29 31| 37 41 4|
|00001cc0| 33 20 34 37 20 35 33 20 | 35 39 20 36 31 20 36 37 |3 47 53 |59 61 67|
|00001cd0| 20 37 31 20 37 33 20 37 | 39 20 38 33 20 38 39 29 | 71 73 7|9 83 89)|
|00001ce0| 20 73 6d 61 6c 6c 2d 70 | 72 69 6d 65 73 20 39 31 | small-p|rimes 91|
|00001cf0| 20 37 39 32 31 20 74 20 | 70 72 2d 6c 69 73 74 20 | 7921 t |pr-list |
|00001d00| 70 72 69 6d 65 20 33 20 | 32 20 6e 69 6c 20 35 20 |prime 3 |2 nil 5 |
|00001d10| 37 20 69 73 2d 70 72 69 | 6d 65 20 66 61 63 74 6f |7 is-pri|me facto|
|00001d20| 72 32 20 66 61 63 74 6f | 72 31 20 36 5d 20 33 20 |r2 facto|r1 6] 3 |
|00001d30| 22 5c 0a 52 65 74 75 72 | 6e 20 6e 6f 6e 2d 6e 69 |"\.Retur|n non-ni|
|00001d40| 6c 20 69 66 66 20 4e 20 | 69 73 20 70 72 69 6d 65 |l iff N |is prime|
|00001d50| 2e 22 5d 29 0a 28 70 72 | 6f 76 69 64 65 20 27 68 |."]).(pr|ovide 'h|
|00001d60| 61 73 68 74 29 0a | |asht). | |
+--------+-------------------------+-------------------------+--------+--------+