Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- coerce :: a -> b
- coerce x = REDUCE (cast x) if a and b are incompatible
- x otherwise
- class Cast a, b where {cast :: a -> b };
- -- ¬:: is an operator, literally meaning: don’t cast
- --(!) is the reduction operator. Perform one stage of reduction.
- -- Reduce on demand
- instance Cast Exp c, c where { inline cast = ¬::(!)(x::(Exp c) -> ¬::(!)x) };
Add Comment
Please, Sign In to add comment