mirror of
https://github.com/vlang/v.git
synced 2025-09-13 14:32:26 +03:00
raw strings with r'raw'
This commit is contained in:
parent
ebc50432c7
commit
6a0599b5f4
3 changed files with 28 additions and 13 deletions
|
@ -464,3 +464,10 @@ fn test_repeat() {
|
|||
s := 'V! '
|
||||
assert s.repeat(5) == 'V! V! V! V! V! '
|
||||
}
|
||||
|
||||
fn test_raw() {
|
||||
raw := r'raw\nstring'
|
||||
lines := raw.split('\n')
|
||||
assert lines.len == 1
|
||||
println('raw string: "$raw"')
|
||||
}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue