diff options
Diffstat (limited to 'test/compile_errors.zig')
| -rw-r--r-- | test/compile_errors.zig | 10 |
1 files changed, 10 insertions, 0 deletions
diff --git a/test/compile_errors.zig b/test/compile_errors.zig index 801d0464ea..21c8822eb3 100644 --- a/test/compile_errors.zig +++ b/test/compile_errors.zig @@ -175,6 +175,16 @@ pub fn addCases(ctx: *TestContext) !void { } { + const case = ctx.obj("isolated carriage return in multiline string literal", .{}); + case.backend = .stage2; + + case.addError("const foo = \\\\\test\r\r rogue carriage return\n;", &[_][]const u8{ + ":1:19: error: expected ';' after declaration", + ":1:20: note: invalid byte: '\\r'", + }); + } + + { const case = ctx.obj("missing semicolon at EOF", .{}); case.addError( \\const foo = 1 |
