]> gitweb.factorcode.org Git - factor.git/commitdiff
peg.ebnf: don't need to use syntax words.
authorJohn Benediktsson <mrjbq7@gmail.com>
Mon, 23 Nov 2020 21:25:51 +0000 (13:25 -0800)
committerJohn Benediktsson <mrjbq7@gmail.com>
Mon, 23 Nov 2020 21:35:13 +0000 (13:35 -0800)
basis/peg/ebnf/ebnf.factor

index f05b1ab3c0689f630e79072b4bb7ed64ddf43fb9..1061cfaac7e3727ade3fd6d4514144472ab9ba40 100644 (file)
@@ -18,7 +18,7 @@ ERROR: no-rule rule parser ;
 <PRIVATE
 
 : lookup-rule ( rule parser -- rule' )
-        2dup rule [ 2nip ] [ no-rule ] if* ;
+    2dup rule [ 2nip ] [ no-rule ] if* ;
 
 TUPLE: tokenizer-tuple any one many ;
 
@@ -478,11 +478,10 @@ ERROR: bad-effect quot effect ;
     ! so we don't pollute the manifest qualified-vocabs
     ! and also so restarts don't add multiple times
     qualified-vocabs length
-    "syntax" { "[let" ":>" } add-words-from
     "kernel" { "dup" "nip" "over" } add-words-from
     "sequences" { "nth" } add-words-from
     [ string-lines parse-lines ] dip
-    dup 3 + qualified-vocabs delete-slice ;
+    dup 2 + qualified-vocabs delete-slice ;
 
 M: ebnf-action (transform)
     ebnf-transform check-action-effect action ;