mirror of
https://github.com/Reuh/anselme.git
synced 2025-10-27 16:49:31 +00:00
[language] allow multiline strings
This commit is contained in:
parent
eaadb4ace6
commit
a702f250f9
13 changed files with 38 additions and 39 deletions
|
|
@ -1,7 +1,6 @@
|
|||
--# run #--
|
||||
--- text ---
|
||||
| {}"" {}"\"Name: Darmanin\\\
|
||||
Age: 38\"" {}"" |
|
||||
| {}"" {}"\"Name: Darmanin\nAge: 38\"" {}"" |
|
||||
--- return ---
|
||||
()
|
||||
--# saved #--
|
||||
|
|
|
|||
|
|
@ -1,25 +1,15 @@
|
|||
--# run #--
|
||||
--- text ---
|
||||
| {}"" {}"1" {}"" {}"\
|
||||
" {}"" |
|
||||
| {}"" {}"2" {}"" {}"\
|
||||
" {}"" |
|
||||
| {}"" {}"3" {}"" {}"\
|
||||
" {}"" |
|
||||
| {}"" {}"4" {}"" {}"\
|
||||
" {}"" |
|
||||
| {}"" {}"5" {}"" {}"\
|
||||
" {}"" |
|
||||
| {}"" {}"6" {}"" {}"\
|
||||
" {}"" |
|
||||
| {}"" {}"7" {}"" {}"\
|
||||
" {}"" |
|
||||
| {}"" {}"8" {}"" {}"\
|
||||
" {}"" |
|
||||
| {}"" {}"9" {}"" {}"\
|
||||
" {}"" |
|
||||
| {}"" {}"10" {}"" {}"\
|
||||
" {}"" |
|
||||
| {}"" {}"1" {}"" |
|
||||
| {}"" {}"2" {}"" |
|
||||
| {}"" {}"3" {}"" |
|
||||
| {}"" {}"4" {}"" |
|
||||
| {}"" {}"5" {}"" |
|
||||
| {}"" {}"6" {}"" |
|
||||
| {}"" {}"7" {}"" |
|
||||
| {}"" {}"8" {}"" |
|
||||
| {}"" {}"9" {}"" |
|
||||
| {}"" {}"10" {}"" |
|
||||
--- text ---
|
||||
| {}"" {}"11" {}"" |
|
||||
--- return ---
|
||||
|
|
|
|||
5
test/results/multiline string.ans
Normal file
5
test/results/multiline string.ans
Normal file
|
|
@ -0,0 +1,5 @@
|
|||
--# run #--
|
||||
--- return ---
|
||||
"foo\nbar\n\ta\n\tb\n\t c\n d"
|
||||
--# saved #--
|
||||
{}
|
||||
|
|
@ -4,10 +4,9 @@
|
|||
--- text ---
|
||||
| {}"quote " {}"\"" {}"" |
|
||||
--- text ---
|
||||
| {}"other codes " {}"\
|
||||
" {}" " {}"\\" {}" " {}"\9" {}" " {}"{" {}"braces}" |
|
||||
| {}"other codes " {}"\n" {}" " {}"\" {}" " {}"\t" {}" " {}"{" {}"braces}" |
|
||||
--- text ---
|
||||
| {}"" {}"escaping expressions abc and {stuff} \\ and quotes \"" {}"" |
|
||||
| {}"" {}"escaping expressions abc and {stuff} \ and quotes \"" {}"" |
|
||||
--- return ---
|
||||
()
|
||||
--# saved #--
|
||||
|
|
|
|||
|
|
@ -4,8 +4,7 @@
|
|||
--- text ---
|
||||
| {}"quote " {}"\"" {}"" |
|
||||
--- text ---
|
||||
| {}"other codes " {}"\
|
||||
" {}" " {}"\\" {}" " {}"\9" {}"" |
|
||||
| {}"other codes " {}"\n" {}" " {}"\" {}" " {}"\t" {}"" |
|
||||
--- text ---
|
||||
| {}"decorators " {}"#" {}" tag " {}"~" {}" condition " {}"$" {}" fn" |
|
||||
--- text ---
|
||||
|
|
|
|||
|
|
@ -1,5 +1,5 @@
|
|||
:i = 0
|
||||
|
||||
while($()(i += 1; i <= 10), $| {i}\n |!)
|
||||
while($()(i += 1; i <= 10), $| {i} |!)
|
||||
|
||||
|{i}
|
||||
|
|
|
|||
6
test/tests/multiline string.ans
Normal file
6
test/tests/multiline string.ans
Normal file
|
|
@ -0,0 +1,6 @@
|
|||
"foo
|
||||
bar
|
||||
a
|
||||
b
|
||||
c
|
||||
d"
|
||||
Loading…
Add table
Add a link
Reference in a new issue