author | haftmann |
Fri, 30 Nov 2007 20:13:08 +0100 | |
changeset 25514 | 4b508bb31a6c |
parent 25182 | 64e3f45dc6f4 |
child 25731 | b3e415b0cf5c |
permissions | -rw-r--r-- |
module Codegen where { import qualified Nat; class Null a where { nulla :: a; }; heada :: (Codegen.Null a) => [a] -> a; heada (x : xs) = x; heada [] = Codegen.nulla; null_option :: Maybe a; null_option = Nothing; instance Codegen.Null (Maybe a) where { nulla = Codegen.null_option; }; dummy :: Maybe Nat.Nat; dummy = Codegen.heada [Just (Nat.Suc Nat.Zero_nat), Nothing]; }