diff options
author | Nirmal Patel <nirmal@nirmal.dev> | 2023-12-27 17:49:58 -0500 |
---|---|---|
committer | Arthur Cohen <arthur.cohen@embecosm.com> | 2024-01-30 12:36:51 +0100 |
commit | 8b7d6adbbb886039f8c6e14a581dcbc9c63ce380 (patch) | |
tree | 2652d0a7a44a472e126dd1125c8e5508e98c8f32 /gcc/rust/parse | |
parent | 14025f735967c1909f2e722210f8c4e694b9ee51 (diff) | |
download | gcc-8b7d6adbbb886039f8c6e14a581dcbc9c63ce380.zip gcc-8b7d6adbbb886039f8c6e14a581dcbc9c63ce380.tar.gz gcc-8b7d6adbbb886039f8c6e14a581dcbc9c63ce380.tar.bz2 |
gccrs: Handle newlines during string parsing while lexing
If newline strings are encountered while lexing, the lexer now handles
newline characters by incrementing current line number. This provides
correct line number when displaying errors. If the lexer encounters end
of file before string end, then it will use the start of the string as
the location to an report error.
gcc/rust/ChangeLog:
* lex/rust-lex.cc (Lexer::parse_byte_string): Handle newline
while parsing byte strings
(Lexer::parse_string): Handle newline while parsing strings
Signed-off-by: Nirmal Patel <nirmal@nirmal.dev>
Diffstat (limited to 'gcc/rust/parse')
0 files changed, 0 insertions, 0 deletions