diff options
| author | Andrew Kelley <andrew@ziglang.org> | 2019-01-20 14:09:46 -0500 |
|---|---|---|
| committer | Andrew Kelley <andrew@ziglang.org> | 2019-01-20 14:09:46 -0500 |
| commit | aee973829d7b101d76e94d9aee15b1bef33094c0 (patch) | |
| tree | 9ce52349a3124d2229a3d125c801fdc39dcdf734 /test/compile_errors.zig | |
| parent | c968d8756c9158433a9fb30db1f4989d1148cc7f (diff) | |
| parent | 1357bc7430e48137b249c6930b4f03c48efa0f33 (diff) | |
| download | zig-aee973829d7b101d76e94d9aee15b1bef33094c0.tar.gz zig-aee973829d7b101d76e94d9aee15b1bef33094c0.zip | |
Merge branch 'kristate-zig-backport-issue1883'
Diffstat (limited to 'test/compile_errors.zig')
| -rw-r--r-- | test/compile_errors.zig | 9 |
1 files changed, 9 insertions, 0 deletions
diff --git a/test/compile_errors.zig b/test/compile_errors.zig index 880a96a322..d9603ba4ff 100644 --- a/test/compile_errors.zig +++ b/test/compile_errors.zig @@ -2,6 +2,15 @@ const tests = @import("tests.zig"); pub fn addCases(cases: *tests.CompileErrorContext) void { cases.add( + "compile log a pointer to an opaque value", + \\export fn entry() void { + \\ @compileLog(@ptrCast(*const c_void, &entry)); + \\} + , + ".tmp_source.zig:2:5: error: found compile log statement", + ); + + cases.add( "duplicate boolean switch value", \\comptime { \\ const x = switch (true) { |
