diff options
author | Eduardo Julian | 2021-08-09 23:02:01 -0400 |
---|---|---|
committer | Eduardo Julian | 2021-08-09 23:02:01 -0400 |
commit | 464b6e8f5e6c62f58fa8c7ff61ab2ad215e98bd1 (patch) | |
tree | 1ae9d95956cee4251cd29a3e24c246c4360d567d /stdlib/source/program/aedifex/hash.lux | |
parent | f621a133e6e0a516c0586270fea8eaffb4829d82 (diff) |
Improved single-line comment syntax (from "##" to "...").
Diffstat (limited to 'stdlib/source/program/aedifex/hash.lux')
-rw-r--r-- | stdlib/source/program/aedifex/hash.lux | 14 |
1 files changed, 7 insertions, 7 deletions
diff --git a/stdlib/source/program/aedifex/hash.lux b/stdlib/source/program/aedifex/hash.lux index 95247c471..2e46286ea 100644 --- a/stdlib/source/program/aedifex/hash.lux +++ b/stdlib/source/program/aedifex/hash.lux @@ -21,9 +21,9 @@ [type abstract]]]) -## TODO: Replace with pure-Lux implementations of these algorithms -## https://en.wikipedia.org/wiki/SHA-1#SHA-1_pseudocode -## https://en.wikipedia.org/wiki/MD5#Algorithm +... TODO: Replace with pure-Lux implementations of these algorithms +... https://en.wikipedia.org/wiki/SHA-1#SHA-1_pseudocode +... https://en.wikipedia.org/wiki/MD5#Algorithm (import: java/lang/String) (import: java/security/MessageDigest @@ -127,7 +127,7 @@ (#.Some [head tail]) (do try.monad [head (\ n.hex decode head) - output (binary.write/64 index head output)] + output (binary.write/64! index head output)] (recur tail (inc chunk) output)) #.None @@ -139,9 +139,9 @@ [head (\ n.hex decode input) output (<write> index head output)] (constructor output))]) - ([1 binary.write/8] - [2 binary.write/16] - [4 binary.write/32]) + ([1 binary.write/8!] + [2 binary.write/16!] + [4 binary.write/32!]) _ (exception.except ..not_a_hash [(..encoding_size size) encoded]))))) (exception.except ..not_a_hash [(..encoding_size size) encoded])))) |