Explorar o código

Add the show method to Nat

DricomDragon %!s(int64=5) %!d(string=hai) anos
pai
achega
e0265c011e
Modificáronse 1 ficheiros con 1 adicións e 1 borrados
  1. 1 1
      peano.hs

+ 1 - 1
peano.hs

@@ -1,4 +1,4 @@
-data Nat = Zero | Succ Nat
+data Nat = Zero | Succ Nat deriving Show
 
 intValOf thisNat = case thisNat of
 	Zero -> 0