init commit again

This commit is contained in:
Peter
2023-11-01 09:29:33 +01:00
parent 448147e7da
commit d6c745207b
250 changed files with 15552 additions and 1 deletions

View File

@@ -0,0 +1,19 @@
general {
funcon-term:
initialise-binding
finalise-throwing
sequential(
handle-thrown(
throw 1,
catch-else-throw(1, print 1)),
handle-thrown(
handle-thrown(throw 2,
catch-else-throw(1, fail)),
catch-else-throw(2, print 2)))
;
}
tests {
result-term: null-value;
standard-out: [1, 2];
}

View File

@@ -0,0 +1,17 @@
general {
funcon-term:
finalise-throwing
handle-recursively(
throw 1,
if-true-else(
is-less(given,4),
sequential(print given, throw integer-add(1,given)),
print"OK")
)
;
}
tests {
result-term: null-value;
standard-out: [1, 2, 3, "OK"];
}

View File

@@ -0,0 +1,17 @@
general {
funcon-term:
finalise-throwing
sequential(
print handle-thrown(1, fail),
handle-thrown(print 2, fail),
handle-thrown(
sequential(print 3, throw(sequential(print 4, 5))),
print given)
)
;
}
tests {
result-term: null-value;
standard-out: [1, 2, 3, 4, 5];
}