Mercurial > projects > dcrypt
diff dcrypt/misc/checksums/Adler32.d @ 28:ad687db713a4
Further reworked the code for hash padding. Replaced all instances of 'char[]' with 'string' and removed a few 'const' modifiers as per Glenn Haecker's patch for D2 compatibility. Updated CONTRIBUTORS file.
author | Thomas Dixon <reikon@reikon.us> |
---|---|
date | Sun, 10 May 2009 22:38:48 -0400 |
parents | 176c933827a8 |
children | 21847420b1ac |
line wrap: on
line diff
--- a/dcrypt/misc/checksums/Adler32.d Sat May 09 23:29:20 2009 -0400 +++ b/dcrypt/misc/checksums/Adler32.d Sun May 10 22:38:48 2009 -0400 @@ -33,13 +33,13 @@ return (s2 << 16) + s1; } - char[] name() { + string name() { return "Adler32"; } debug (UnitTest) { unittest { - static char[][] test_inputs = [ + static string[] test_inputs = [ "", "a", "checksum", @@ -54,7 +54,7 @@ ]; Adler32 adler32 = new Adler32; - foreach (uint i, char[] j; test_inputs) + foreach (uint i, string j; test_inputs) assert(adler32.compute(j) == test_results[i], adler32.name); } }