31 Jan
2006
31 Jan
'06
3:09 a.m.
Robert Dockins wrote:
While cleaning up my home directory, I discovered some code I worked on a while ago which implements type level arithmetic.
I know for the usual Peano representation of natural numbers, at least, it's possible to represent addition and subtraction with a single class with two fundeps (because classes represent relations between types rather than functions on them). See <http://haskell.org/haskellwiki/Peano_numbers>.