Improved examples
This commit is contained in:
parent
d8cefb2923
commit
629a9a6d05
|
@ -1,7 +1,7 @@
|
||||||
?(?0 ()) (This example prints to the console and demonstrates how to delay the execution of a rule.)
|
?(?0 ()) (This example prints to the console and demonstrates how to delay the execution of a rule.)
|
||||||
|
|
||||||
<> (NAME) (Modal)
|
<> (NAME) (Modal)
|
||||||
<> (?: print) (?:)
|
<> (?: print String) (?:)
|
||||||
<> (delay ?x) (?x delay)
|
<> (String ?x) (?x String)
|
||||||
|
|
||||||
delay (Welcome to NAME \nHave fun!\n\n) print
|
String (Welcome to NAME \nHave fun!\n\n) print
|
||||||
|
|
|
@ -1 +0,0 @@
|
||||||
?((?x ?y) (?y ?x)) foo bar
|
|
|
@ -1,8 +0,0 @@
|
||||||
<> (foo ?x) (?x)
|
|
||||||
<> (map ?x (list ?l)) (map/l map/x ?x ?l)
|
|
||||||
<> (map/x ?x (?h ?t)) (?x ?h (map/x ?x ?t))
|
|
||||||
<> (map/x ?x (?h)) (map/r (?x ?h))
|
|
||||||
<> (?h (map/r ?t)) (?map/r (?h ?t))
|
|
||||||
<> (map/l map/r ?l) (list ?l)
|
|
||||||
|
|
||||||
map foo (list (1 (2 (3 (4 (5))))))
|
|
5
makefile
5
makefile
|
@ -8,11 +8,10 @@ all: dest
|
||||||
dest:
|
dest:
|
||||||
@ mkdir -p bin
|
@ mkdir -p bin
|
||||||
run: all bin/modal
|
run: all bin/modal
|
||||||
@ bin/modal examples/hello.modal
|
@ bin/modal examples/hello.modal 2> /dev/null
|
||||||
test: bin/modal-debug bin/modal
|
test: bin/modal-debug bin/modal
|
||||||
@ bin/modal -v
|
@ bin/modal -v
|
||||||
@ bin/modal-debug examples/test.modal "(arg1) (arg2 (arg3))"
|
@ bin/modal-debug examples/tests.modal 2> /dev/null
|
||||||
@ bin/modal examples/test.modal 2> /dev/null
|
|
||||||
install: bin/modal
|
install: bin/modal
|
||||||
cp bin/modal ~/bin/
|
cp bin/modal ~/bin/
|
||||||
uninstall:
|
uninstall:
|
||||||
|
|
Loading…
Reference in New Issue