Merge branch 'baldurk-raw-strings-issue-948'
* baldurk-raw-strings-issue-948: Experimental fix for delimiter leakage in raw strings.
This commit is contained in:
commit
a4e48b18e5
1 changed files with 3 additions and 0 deletions
|
|
@ -749,6 +749,9 @@ static int look(Scanner *s) {
|
|||
}
|
||||
|
||||
if (Strcmp( str_delimiter, end_delimiter )==0) {
|
||||
int len = Len(s->text);
|
||||
Delslice(s->text, len - 2 - Len(str_delimiter), len); /* Delete ending )XXXX" */
|
||||
Delslice(s->text, 0, Len(str_delimiter) + 1); /* Delete starting XXXX( */
|
||||
Delete( end_delimiter ); /* Correct end delimiter )XXXX" occurred */
|
||||
Delete( str_delimiter );
|
||||
str_delimiter = 0;
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue