diff options
Diffstat (limited to '')
-rw-r--r-- | stdlib/source/program/aedifex/hash.lux | 20 |
1 files changed, 10 insertions, 10 deletions
diff --git a/stdlib/source/program/aedifex/hash.lux b/stdlib/source/program/aedifex/hash.lux index 4e83b8f07..95247c471 100644 --- a/stdlib/source/program/aedifex/hash.lux +++ b/stdlib/source/program/aedifex/hash.lux @@ -31,18 +31,18 @@ (#static getInstance [java/lang/String] java/security/MessageDigest) (digest [[byte]] [byte])]) -(abstract: #export SHA-1 Any) -(abstract: #export MD5 Any) +(abstract: .public SHA-1 Any) +(abstract: .public MD5 Any) -(abstract: #export (Hash h) +(abstract: .public (Hash h) Binary - (def: #export data + (def: .public data (All [h] (-> (Hash h) Binary)) (|>> :representation)) (template [<name> <kind> <algorithm>] - [(def: #export (<name> value) + [(def: .public (<name> value) (-> Binary (Hash <kind>)) (|> (java/security/MessageDigest::getInstance [<algorithm>]) (java/security/MessageDigest::digest [value]) @@ -77,14 +77,14 @@ (def: hex_per_chunk (n.* hex_per_byte i64.bytes_per_i64)) - (exception: #export (not_a_hash {size Nat} {value Text}) + (exception: .public (not_a_hash {size Nat} {value Text}) (exception.report ["Pseudo hash" (%.text value)] ["Expected size" (%.nat size)] ["Actual size" (%.nat (text.size value))])) (template [<name> <size>] - [(exception: #export (<name> {data Binary}) + [(exception: .public (<name> {data Binary}) (exception.report ["Pseudo hash" (%.text (..encode data))] ["Expected size" (%.nat <size>)] @@ -95,7 +95,7 @@ ) (template [<name> <kind> <size> <exception>] - [(def: #export (<name> data) + [(def: .public (<name> data) (-> Binary (Try (Hash <kind>))) (if (n.= <size> (binary.size data)) (#try.Success (:abstraction data)) @@ -146,7 +146,7 @@ (exception.except ..not_a_hash [(..encoding_size size) encoded])))) (template [<codec> <hash> <nat> <constructor>] - [(implementation: #export <codec> + [(implementation: .public <codec> (Codec Text (Hash <hash>)) (def: encode (|>> :representation ..encode)) @@ -156,7 +156,7 @@ [md5_codec MD5 ..md5::size ..as_md5] ) - (implementation: #export equivalence + (implementation: .public equivalence (All [h] (Equivalence (Hash h))) (def: (= reference subject) |