modern: Fix strings. They were out of order.
parent
5bb1c2b520
commit
4ede4769e2
|
@ -1,6 +1,6 @@
|
||||||
! Copyright (C) 2017 Doug Coleman.
|
! Copyright (C) 2017 Doug Coleman.
|
||||||
! See http://factorcode.org/license.txt for BSD license.
|
! See http://factorcode.org/license.txt for BSD license.
|
||||||
USING: modern modern.slices tools.test ;
|
USING: modern modern.slices multiline tools.test ;
|
||||||
IN: modern.tests
|
IN: modern.tests
|
||||||
|
|
||||||
! Comment
|
! Comment
|
||||||
|
@ -129,3 +129,13 @@ IN: modern.tests
|
||||||
{ f } [ "FOO:" section-open? ] unit-test
|
{ f } [ "FOO:" section-open? ] unit-test
|
||||||
{ f } [ ";FOO" section-close? ] unit-test
|
{ f } [ ";FOO" section-close? ] unit-test
|
||||||
{ f } [ "FOO" section-close? ] unit-test
|
{ f } [ "FOO" section-close? ] unit-test
|
||||||
|
|
||||||
|
|
||||||
|
! Strings
|
||||||
|
{
|
||||||
|
{ { "url\"" "google.com" "\"" } }
|
||||||
|
} [ [[ url"google.com" ]] string>literals >strings ] unit-test
|
||||||
|
|
||||||
|
{
|
||||||
|
{ { "\"" "google.com" "\"" } }
|
||||||
|
} [ [[ "google.com" ]] string>literals >strings ] unit-test
|
|
@ -120,7 +120,7 @@ MACRO:: read-matched ( ch -- quot: ( n string tag -- n' string slice' ) )
|
||||||
n' [ n string string-expected-got-eof ] unless
|
n' [ n string string-expected-got-eof ] unless
|
||||||
n n' 1 - string <slice>
|
n n' 1 - string <slice>
|
||||||
n' 1 - n' string <slice>
|
n' 1 - n' string <slice>
|
||||||
tag 1 cut-slice* 4array ;
|
tag -rot 3array ;
|
||||||
|
|
||||||
: take-comment ( n string slice -- n' string comment )
|
: take-comment ( n string slice -- n' string comment )
|
||||||
2over ?nth char: \[ = [
|
2over ?nth char: \[ = [
|
||||||
|
|
Loading…
Reference in New Issue