
30 Nov
2011
30 Nov
'11
11:55 p.m.
I'd like to write a small module using Data.TypeLevel.Num. It has type level constants, variables, addition, and maximum, which is pretty much all I need. But I've never used it before, and there's one thing I want to do that I don't understand how to do. val :: Nat t => t -> Int val _ = t as an Int e.g., if x :: D8 then val x = 8. The "value-level reflection functions" in Data.TypeLevel.Num.Ops all seem to be 'undefined'.