Remove MATCH-VARS not used in pegs
parent
e00a392736
commit
00d09d20e2
|
@ -1,7 +1,7 @@
|
||||||
! Copyright (C) 2007, 2008 Chris Double.
|
! Copyright (C) 2007, 2008 Chris Double.
|
||||||
! See http://factorcode.org/license.txt for BSD license.
|
! See http://factorcode.org/license.txt for BSD license.
|
||||||
USING: kernel sequences strings fry namespaces math assocs shuffle
|
USING: kernel sequences strings fry namespaces math assocs shuffle
|
||||||
vectors arrays combinators.lib math.parser match
|
vectors arrays combinators.lib math.parser
|
||||||
unicode.categories sequences.lib compiler.units parser
|
unicode.categories sequences.lib compiler.units parser
|
||||||
words quotations effects memoize accessors locals effects splitting ;
|
words quotations effects memoize accessors locals effects splitting ;
|
||||||
IN: peg
|
IN: peg
|
||||||
|
@ -265,8 +265,6 @@ SYMBOL: id
|
||||||
|
|
||||||
TUPLE: token-parser symbol ;
|
TUPLE: token-parser symbol ;
|
||||||
|
|
||||||
MATCH-VARS: ?token ;
|
|
||||||
|
|
||||||
: parse-token ( input string -- result )
|
: parse-token ( input string -- result )
|
||||||
#! Parse the string, returning a parse result
|
#! Parse the string, returning a parse result
|
||||||
dup >r ?head-slice [
|
dup >r ?head-slice [
|
||||||
|
@ -388,9 +386,6 @@ M: optional-parser (compile) ( parser -- quot )
|
||||||
p1>> compiled-parser 1quotation '[ @ check-optional ] ;
|
p1>> compiled-parser 1quotation '[ @ check-optional ] ;
|
||||||
|
|
||||||
TUPLE: semantic-parser p1 quot ;
|
TUPLE: semantic-parser p1 quot ;
|
||||||
MATCH-VARS: ?quot ;
|
|
||||||
|
|
||||||
MATCH-VARS: ?parser ;
|
|
||||||
|
|
||||||
: check-semantic ( result quot -- result )
|
: check-semantic ( result quot -- result )
|
||||||
over [
|
over [
|
||||||
|
@ -421,8 +416,6 @@ M: ensure-not-parser (compile) ( parser -- quot )
|
||||||
|
|
||||||
TUPLE: action-parser p1 quot ;
|
TUPLE: action-parser p1 quot ;
|
||||||
|
|
||||||
MATCH-VARS: ?action ;
|
|
||||||
|
|
||||||
: check-action ( result quot -- result )
|
: check-action ( result quot -- result )
|
||||||
over [
|
over [
|
||||||
over ast>> swap call >>ast
|
over ast>> swap call >>ast
|
||||||
|
|
Loading…
Reference in New Issue