mozilla/rust — pull request #7207 by DaGenix (2013-06-18 04:52:28+00:00)
Title: Remove @ types from Sha1 implementation, create Digest trait, and implement most of SHA-2 functions

This pull request contains an un-optimized implementation of most of the SHA-2 functions (everything but the variable output size versions). I also created a common trait for all of the interesting methods for working with hash functions and updated the existing SHA-1 code to use it. Finally, while working with the SHA-1 code, I got rid of the use of @ types and type objects.

I did my best to try to follow Rust conventions, but, there are so many different conventions in the code base right now that I'm not sure if I'm following the correct one or not. Anyway, I'm happy to rework if I didn't get the coding convention right (or if there are bugs!).