txon: can just use replace instead of re-replace.

db4
John Benediktsson 2014-04-22 17:52:57 -07:00
parent 478cc0bb98
commit 2ed87ace0f
1 changed files with 4 additions and 4 deletions

View File

@ -2,15 +2,15 @@
! See http://factorcode.org/license.txt for BSD license
USING: assocs combinators combinators.short-circuit formatting
grouping hashtables io kernel make math math.parser regexp
sequences splitting strings unicode.categories ;
grouping hashtables io kernel make math math.parser sequences
splitting strings unicode.categories ;
IN: txon
<PRIVATE
: decode-value ( string -- string' )
R" \\`" "`" re-replace ;
"\\`" "`" replace ;
: `? ( ch1 ch2 -- ? )
[ CHAR: \ = not ] [ CHAR: ` = ] bi* and ;
@ -58,7 +58,7 @@ PRIVATE>
<PRIVATE
: encode-value ( string -- string' )
R" `" "\\`" re-replace ;
"`" "\\`" replace ;
PRIVATE>