
1 Jul
2010
1 Jul
'10
9:19 p.m.
Hello, C++ `Concepts', which almost made it into the C++0x standard, are roughly similar to Haskell type classes. The proposal for concepts in C++ had a feature called axioms, which allow the programmer to specify semantics on the functions the concept contains. This allows for enforcing things such as the Monad Laws, as well as letting the compiler make certain optimizations it may not have been able to make without axiomatic guarantees. Why does Haskell not have a similar functionality in its type classes? Was there not time, desire, etc.? Or are there technical limitations? Thanks, ~j