summaryrefslogtreecommitdiff
path: root/examples/maybe.sin
diff options
context:
space:
mode:
authorTom Harley2020-01-11 19:46:15 +0000
committerTom Harley2020-01-11 19:46:15 +0000
commit9e87372371794bc3e7d46698141966c00acaad0e (patch)
tree068da13d97cefed2e49ab06843e1dd9d97c32f6a /examples/maybe.sin
parentAdded int width specifiers (diff)
downloadsinter-9e87372371794bc3e7d46698141966c00acaad0e.tar.gz
sinter-9e87372371794bc3e7d46698141966c00acaad0e.zip

Tidying up

  • Removed unused example files
  • Removed redundant common.c
  • Added extra files to make sure the current version compiles the nqueens solution correctly
  • Added extensionless files to .gitignore
  • Added a way to install sinter
Diffstat (limited to 'examples/maybe.sin')
-rw-r--r--examples/maybe.sin22
1 files changed, 0 insertions, 22 deletions
diff --git a/examples/maybe.sin b/examples/maybe.sin
deleted file mode 100644
index 91367cd..0000000
--- a/examples/maybe.sin
+++ /dev/null
@@ -1,22 +0,0 @@
-[type just_ [kind val]]
-[type none_ [kind]]
-
-[def just [val]
- [just_ 1 val]]
-
-[def just.val [x]
- [just_.val x]]
-
-[def none []
- [none_ 0]]
-
-[def has_value [x]
- [just_.kind x]]
-
-[def Maybe.>>= [a f]
- [if [has_value a]
- [f [just.val a]]
- a]]
-
-[def Maybe.return [x]
- [just x]]