From 0f228d2d25f292b7d841c84cfa8b8f02229c993a Mon Sep 17 00:00:00 2001 From: Bruce Hill Date: Thu, 14 Sep 2017 00:09:54 -0700 Subject: Changed comments to use # and #.. instead of (# #), which is more consistent with the language's attitude towards code blocks and indentation. No more long-range action closing parens. --- examples/sample_code.nom | 15 +++++++++------ 1 file changed, 9 insertions(+), 6 deletions(-) mode change 100755 => 100644 examples/sample_code.nom (limited to 'examples/sample_code.nom') diff --git a/examples/sample_code.nom b/examples/sample_code.nom old mode 100755 new mode 100644 index c8b48f7..63078d7 --- a/examples/sample_code.nom +++ b/examples/sample_code.nom @@ -1,18 +1,21 @@ -(# This is just a comment #) -(# Nested comments (# like this #) work fine #) +# This is just a comment +#.. Block comments + start with a #.. and + continue until dedent + run file "core.nom" say "foo" say (4) -(# "rule" is just a function that takes a function call spec and a block of code to run, - and stores the function definition #) +#.. "rule" is just a function that takes a function call spec and a block of code to run, + and stores the function definition rule "fart": say "poot" fart -(# multi-line strings: #) +# multi-line strings: say ".." | Once upon a time |there was a very @@ -30,7 +33,7 @@ say ".." |(done) | -rule "doublefart": (# this farts twice #) +rule "doublefart": # this farts twice say "poot" say "poot" -- cgit v1.2.3