new accessors
parent
7b4347d5d2
commit
afbe5df0bd
|
@ -63,10 +63,8 @@ M: f text-matches?
|
||||||
|
|
||||||
M: string-matcher text-matches?
|
M: string-matcher text-matches?
|
||||||
[
|
[
|
||||||
dup string-matcher-string
|
[ string>> ] [ ignore-case?>> ] bi string-head?
|
||||||
swap string-matcher-ignore-case?
|
] keep string>> length and ;
|
||||||
string-head?
|
|
||||||
] keep string-matcher-string length and ;
|
|
||||||
|
|
||||||
M: regexp text-matches?
|
M: regexp text-matches?
|
||||||
>r >string r> match-head ;
|
>r >string r> match-head ;
|
||||||
|
@ -177,17 +175,17 @@ M: mark-following-rule handle-rule-start
|
||||||
?end-rule
|
?end-rule
|
||||||
mark-token add-remaining-token
|
mark-token add-remaining-token
|
||||||
tuck rule-match-token* next-token,
|
tuck rule-match-token* next-token,
|
||||||
f context get set-line-context-end
|
f context get (>>end)
|
||||||
context get set-line-context-in-rule ;
|
context get (>>in-rule) ;
|
||||||
|
|
||||||
M: mark-following-rule handle-rule-end
|
M: mark-following-rule handle-rule-end
|
||||||
nip rule-match-token* prev-token,
|
nip rule-match-token* prev-token,
|
||||||
f context get set-line-context-in-rule ;
|
f context get (>>in-rule) ;
|
||||||
|
|
||||||
M: mark-previous-rule handle-rule-start
|
M: mark-previous-rule handle-rule-start
|
||||||
?end-rule
|
?end-rule
|
||||||
mark-token
|
mark-token
|
||||||
dup rule-body-token prev-token,
|
dup body-token>> prev-token,
|
||||||
rule-match-token* next-token, ;
|
rule-match-token* next-token, ;
|
||||||
|
|
||||||
: do-escaped ( -- )
|
: do-escaped ( -- )
|
||||||
|
|
|
@ -97,7 +97,7 @@ GENERIC: text-hash-char ( text -- ch )
|
||||||
|
|
||||||
M: f text-hash-char ;
|
M: f text-hash-char ;
|
||||||
|
|
||||||
M: string-matcher text-hash-char string-matcher-string first ;
|
M: string-matcher text-hash-char string>> first ;
|
||||||
|
|
||||||
M: regexp text-hash-char drop f ;
|
M: regexp text-hash-char drop f ;
|
||||||
|
|
||||||
|
|
Loading…
Reference in New Issue