summaryrefslogtreecommitdiff
path: root/test/prints.lm
diff options
context:
space:
mode:
authorAdrian Thurston <thurston@complang.org>2012-12-30 10:08:43 -0500
committerAdrian Thurston <thurston@complang.org>2012-12-30 10:08:43 -0500
commitbf2212dba3e1825f8f2cccd64fe2af14a1d76521 (patch)
treefd138a2f488350aae4e16550572120831216d6bc /test/prints.lm
parent7db01e426f3d5231bdfb1ec46bbed32981e1e62f (diff)
downloadcolm-bf2212dba3e1825f8f2cccd64fe2af14a1d76521.tar.gz
test case for printing to stdout
Diffstat (limited to 'test/prints.lm')
-rw-r--r--test/prints.lm12
1 files changed, 12 insertions, 0 deletions
diff --git a/test/prints.lm b/test/prints.lm
new file mode 100644
index 00000000..cb8e37e5
--- /dev/null
+++ b/test/prints.lm
@@ -0,0 +1,12 @@
+lex
+ token word /[a-z]+/
+ ignore /[\t\n ]+/
+end
+
+def start
+ [word*]
+
+parse Start: start[stdin]
+
+prints( stderr 'fd stderr: ' Start.tree '\n' )
+prints( stdout 'fd stdout: ' Start.tree '\n' )