1.1 --- a/doc-src/IsarAdvanced/Codegen/Thy/examples/Codegen.hs Wed Mar 04 11:05:02 2009 +0100
1.2 +++ /dev/null Thu Jan 01 00:00:00 1970 +0000
1.3 @@ -1,23 +0,0 @@
1.4 -module Codegen where {
1.5 -
1.6 -import qualified Nat;
1.7 -
1.8 -class Null a where {
1.9 - nulla :: a;
1.10 -};
1.11 -
1.12 -heada :: forall a. (Codegen.Null a) => [a] -> a;
1.13 -heada (x : xs) = x;
1.14 -heada [] = Codegen.nulla;
1.15 -
1.16 -null_option :: forall a. Maybe a;
1.17 -null_option = Nothing;
1.18 -
1.19 -instance Codegen.Null (Maybe a) where {
1.20 - nulla = Codegen.null_option;
1.21 -};
1.22 -
1.23 -dummy :: Maybe Nat.Nat;
1.24 -dummy = Codegen.heada [Just (Nat.Suc Nat.Zero_nat), Nothing];
1.25 -
1.26 -}