summaryrefslogtreecommitdiff
path: root/tests/examplefiles/example.snobol
diff options
context:
space:
mode:
authorMartin Harriman <larvacea@mac.com>2011-09-27 17:04:05 -0700
committerMartin Harriman <larvacea@mac.com>2011-09-27 17:04:05 -0700
commit33bb5f7da698217cfcbf22b4e8ed5cf0841a5f66 (patch)
tree797eee591c110fe21ee44fa720750dc3185256f3 /tests/examplefiles/example.snobol
parent2a7deac5ab1e25650a5eb71b134e25bfb8f8be1d (diff)
downloadpygments-33bb5f7da698217cfcbf22b4e8ed5cf0841a5f66.tar.gz
SNOBOL4 lexer
Create a simple lexer for the SNOBOL4 language. The test suite (including the new example.snobol examplefile) passes.
Diffstat (limited to 'tests/examplefiles/example.snobol')
-rw-r--r--tests/examplefiles/example.snobol15
1 files changed, 15 insertions, 0 deletions
diff --git a/tests/examplefiles/example.snobol b/tests/examplefiles/example.snobol
new file mode 100644
index 00000000..26ca5cf4
--- /dev/null
+++ b/tests/examplefiles/example.snobol
@@ -0,0 +1,15 @@
+-SOME RANDOM DIRECTIVE WOULD GO HERE
+*
+* SNOBOL4 example file for lexer
+*
+ SOME.THING_OR_OTHER32 = 1 + 1.0 - 1E3 * 1E-3 ** 2.718284590E0
++ :F(END)S(IN_LOOP)
+ PATTERN = LEN(3) ("GAR" | "BAR")
+IN_LOOP THING = INPUT :F(END)
+ THING LEN(3) ("GAR" | "BAR") :S(OK)
+ OUTPUT = THING " : Failure!" :(IN_LOOP)
+OK OUTPUT = THING ' : "Success"!' :(IN_LOOP)
+END
+FOOBAR
+FOOGAR
+THiNIg