valderman / threefish

Haskell implementation of the Threefish block cipher and the Skein hash function built on it.
BSD 3-Clause "New" or "Revised" License
4 stars 5 forks source link

Key256 and Block256 constructors not exported #1

Closed blanu closed 10 years ago

blanu commented 10 years ago

How do you convert a ByteString to a Key256? Since the Key256 constructor is not exported from its module, I can't figure out how to construct a Key256 outside of the module.

valderman commented 10 years ago

You can use the toBlock function (doc); not exporting the constructor ensures that people don't accidentally create keys of the wrong size.

blanu commented 10 years ago

Okay thanks!