mirror of
https://github.com/ziglang/zig.git
synced 2026-11-22 04:37:39 -05:00
fix parseh bugs
This commit is contained in:
1 parent
e1d5da20a5
commit
cc621cdee3
5 files changed
+100
-80
No files matched your search
+5
-2
@@ -79,11 +79,14 @@ ErrorMsg *err_msg_create_with_offset(Buf *path, size_t line, size_t column, size
|
||||
for (;;) {
|
||||
if (line_start_offset == 0) {
|
||||
break;
|
||||
} else if (source[line_start_offset] == '\n') {
|
||||
}
|
||||
|
||||
line_start_offset -= 1;
|
||||
|
||||
if (source[line_start_offset] == '\n') {
|
||||
line_start_offset += 1;
|
||||
break;
|
||||
}
|
||||
line_start_offset -= 1;
|
||||
}
|
||||
|
||||
size_t line_end_offset = offset;
|
||||
|
||||
Reference in new issue
Block a user