summaryrefslogtreecommitdiff
path: root/test/spec/dec2.txt
diff options
context:
space:
mode:
Diffstat (limited to 'test/spec/dec2.txt')
-rw-r--r--test/spec/dec2.txt8
1 files changed, 8 insertions, 0 deletions
diff --git a/test/spec/dec2.txt b/test/spec/dec2.txt
new file mode 100644
index 0000000..ced6ccd
--- /dev/null
+++ b/test/spec/dec2.txt
@@ -0,0 +1,8 @@
+withDefault : a -> Maybe a -> a
+withDefault default m =
+ case m of
+ Just x ->
+ x
+
+ Nothing ->
+ default