diff options
author | Adrian Thurston <thurston@complang.org> | 2013-04-14 12:19:57 -0400 |
---|---|---|
committer | Adrian Thurston <thurston@complang.org> | 2013-04-14 12:19:57 -0400 |
commit | f62577ebc86ee021f773c766c462e865bc86dc2d (patch) | |
tree | 4bbd0293f777d4ae108f458756b0fc1ced4963bf | |
parent | 0802c2b4ef354e0016a7c35f755b4ed17251f234 (diff) | |
download | colm-f62577ebc86ee021f773c766c462e865bc86dc2d.tar.gz |
eliminated the original send syntax
-rw-r--r-- | colm/colm.lm | 2 | ||||
-rw-r--r-- | test/order1.lm | 7 | ||||
-rw-r--r-- | test/order2.lm | 9 |
3 files changed, 9 insertions, 9 deletions
diff --git a/colm/colm.lm b/colm/colm.lm index c7b5b3d3..63f8e378 100644 --- a/colm/colm.lm +++ b/colm/colm.lm @@ -104,7 +104,6 @@ lex token PERCENT /'%'/ token PLUS /'+'/ token MINUS /'-'/ - token LTLT /'<<'/ token AMPAMP /'&&'/ token BARBAR /'||'/ @@ -461,7 +460,6 @@ def code_factor | [False: FALSE] | [POPEN ParenCodeExpr: code_expr PCLOSE] | [Send: SEND ToVarRef: var_ref Accumulate: accumulate OptEos: opt_eos] -| [ToVarRef: var_ref Send: LTLT Accumulate: accumulate] | [Parse: PARSE OptCapture: opt_capture TypeRef: type_ref OptFieldInit: opt_field_init Accumulate: accumulate] | [ParseStop: PARSE_STOP OptCapture: opt_capture TypeRef: type_ref diff --git a/test/order1.lm b/test/order1.lm index eb3c7859..fa1843be 100644 --- a/test/order1.lm +++ b/test/order1.lm @@ -88,12 +88,13 @@ Output: output Output = construct output [] # Take off the leading C from the input file and send it out. match P [C: c '%%' protocol*] -Output << [$C] -Output << +send Output [$C] +send Output "#include <assert.h> " + eos -print( Output.finish() ) +print( Output.tree ) ##### IN ##### #include "some_header.h" diff --git a/test/order2.lm b/test/order2.lm index 9a8da921..5217c740 100644 --- a/test/order2.lm +++ b/test/order2.lm @@ -75,7 +75,7 @@ def protocol def program [c '%%' protocol*] -alias output accum<c> +alias output parser<c> def port Port: int @@ -90,11 +90,12 @@ Output: output Output = construct output [] # Take off the leading C from the input file and send it out. match P [C: c '%%' protocol*] -Output << [$C] -Output << +send Output [ + $C "#include <assert.h> " -print( Output.finish() ) + ] eos +print( Output.tree ) ##### IN ##### #include "some_header.h" |