| author | |
| committer | |
| log | 2e3fac3626a3edc61eb8afc7c17a19b5fec4b672 |
| tree | 256f79320f2518ee454fbfba342c41863685a573 |
| parent | d5c73a44b796aaaebe748b1a8cb862c7a3dadae1 |
| signature |
backend=auto (now the default if backend is omitted) means to let the compiler
pick whatever backend it wants as the default. This is important for platforms
where we don't yet have a self-hosted backend, such as loongarch64.
Also purge a bunch of redundant target=native.856 files changed, 181 insertions(+), 1567 deletions(-)
test/cases/README.md+4-3| ... | ... | @@ -77,12 +77,13 @@ path will be prepended as a prefix on the test case name. |
| 77 | 77 | |
| 78 | 78 | ```zig |
| 79 | 79 | // run |
| 80 | // backend=stage2,llvm | |
| 80 | // backend=selfhosted,llvm | |
| 81 | 81 | // target=x86_64-linux,x86_64-macos |
| 82 | 82 | ``` |
| 83 | 83 | |
| 84 | 84 | Possible backends are: |
| 85 | 85 | |
| 86 | * `auto`: the default; compiler picks the backend based on robustness. | |
| 86 | 87 | * `stage1`: equivalent to `-fstage1`. |
| 87 | * `stage2`: equivalent to passing `-fno-stage1 -fno-LLVM`. | |
| 88 | * `llvm`: equivalent to `-fLLVM -fno-stage1`. | |
| 88 | * `selfhosted`: equivalent to passing `-fno-llvm -fno-lld`. | |
| 89 | * `llvm`: equivalent to `-fllvm`. |
test/cases/address_of_extern_var_as_const.zig+1-1| ... | ... | @@ -6,5 +6,5 @@ export const p_external_variable = &external_variable; |
| 6 | 6 | |
| 7 | 7 | // compile |
| 8 | 8 | // output_mode=Obj |
| 9 | // backend=stage2,llvm | |
| 9 | // backend=selfhosted,llvm | |
| 10 | 10 | // target=x86_64-linux |
test/cases/array_in_anon_struct.zig+1-1| ... | ... | @@ -18,5 +18,5 @@ pub fn main() !void { |
| 18 | 18 | } |
| 19 | 19 | |
| 20 | 20 | // run |
| 21 | // backend=stage2,llvm | |
| 21 | // backend=selfhosted,llvm | |
| 22 | 22 | // target=x86_64-linux,aarch64-linux |
test/cases/bad_inferred_variable_type.zig deleted-10| ... | ... | @@ -1,10 +0,0 @@ |
| 1 | pub fn main() void { | |
| 2 | var x = null; | |
| 3 | _ = &x; | |
| 4 | } | |
| 5 | ||
| 6 | // error | |
| 7 | // output_mode=Exe | |
| 8 | // backend=stage2 | |
| 9 | // | |
| 10 | // :2:9: error: variable of type '@TypeOf(null)' must be const or comptime |
test/cases/comparison_of_non-tagged_union_and_enum_literal.zig deleted-14| ... | ... | @@ -1,14 +0,0 @@ |
| 1 | export fn entry() void { | |
| 2 | const U = union { A: u32, B: u64 }; | |
| 3 | var u = U{ .A = 42 }; | |
| 4 | var ok = u == .A; | |
| 5 | _ = &u; | |
| 6 | _ = &ok; | |
| 7 | } | |
| 8 | ||
| 9 | // error | |
| 10 | // backend=stage2 | |
| 11 | // target=native | |
| 12 | // | |
| 13 | // :4:14: error: comparison of union and enum literal is only valid for tagged union types | |
| 14 | // :2:15: note: union 'tmp.entry.U' is not a tagged union |
test/cases/compile_errors/@embedFile_with_empty_path.zig-2| ... | ... | @@ -5,7 +5,5 @@ export fn entry() usize { |
| 5 | 5 | } |
| 6 | 6 | |
| 7 | 7 | // error |
| 8 | // backend=stage2 | |
| 9 | // target=native | |
| 10 | 8 | // |
| 11 | 9 | // :1:29: error: file path name cannot be empty |
test/cases/compile_errors/@errorCast_with_bad_type.zig-1| ... | ... | @@ -20,7 +20,6 @@ pub export fn entry4() void { |
| 20 | 20 | } |
| 21 | 21 | |
| 22 | 22 | // error |
| 23 | // backend=stage2 | |
| 24 | 23 | // target=x86_64-linux |
| 25 | 24 | // |
| 26 | 25 | // :4:25: error: expected error set or error union type, found 'comptime_int' |
test/cases/compile_errors/@intCast_on_vec.zig-1| ... | ... | @@ -7,7 +7,6 @@ export fn entry() void { |
| 7 | 7 | // https://github.com/ziglang/zig/issues/13782 |
| 8 | 8 | |
| 9 | 9 | // error |
| 10 | // backend=stage2 | |
| 11 | 10 | // target=x86_64-linux |
| 12 | 11 | // |
| 13 | 12 | // :3:27: error: expected type 'u32', found '@Vector(4, u32)' |
test/cases/compile_errors/@intFromPtr_with_bad_type.zig-2| ... | ... | @@ -5,7 +5,5 @@ pub export fn entry() void { |
| 5 | 5 | } |
| 6 | 6 | |
| 7 | 7 | // error |
| 8 | // backend=stage2 | |
| 9 | // target=native | |
| 10 | 8 | // |
| 11 | 9 | // :2:23: error: comptime-only type 'comptime_int' has no pointer address |
test/cases/compile_errors/@trap_comptime_call.zig-2| ... | ... | @@ -3,7 +3,5 @@ export fn entry() void { |
| 3 | 3 | } |
| 4 | 4 | |
| 5 | 5 | // error |
| 6 | // backend=stage2 | |
| 7 | // target=native | |
| 8 | 6 | // |
| 9 | 7 | // :2:14: error: encountered @trap at comptime |
test/cases/compile_errors/AstGen_comptime_known_struct_is_resolved_before_error.zig-2| ... | ... | @@ -10,8 +10,6 @@ pub export fn entry() void { |
| 10 | 10 | } |
| 11 | 11 | |
| 12 | 12 | // error |
| 13 | // backend=stage2 | |
| 14 | // target=native | |
| 15 | 13 | // |
| 16 | 14 | // :8:12: error: variable of type 'tmp.S1' must be const or comptime |
| 17 | 15 | // :2:8: note: struct requires comptime because of this field |
test/cases/compile_errors/C_pointer_pointing_to_non_C_ABI_compatible_type_or_has_align_attr.zig-2| ... | ... | @@ -6,8 +6,6 @@ export fn a() void { |
| 6 | 6 | } |
| 7 | 7 | |
| 8 | 8 | // error |
| 9 | // backend=stage2 | |
| 10 | // target=native | |
| 11 | 9 | // |
| 12 | 10 | // :3:19: error: C pointers cannot point to non-C-ABI-compatible type 'tmp.Foo' |
| 13 | 11 | // :3:19: note: only extern structs and ABI sized packed structs are extern compatible |
test/cases/compile_errors/C_pointer_to_anyopaque.zig-2| ... | ... | @@ -5,7 +5,5 @@ export fn a() void { |
| 5 | 5 | } |
| 6 | 6 | |
| 7 | 7 | // error |
| 8 | // backend=stage2 | |
| 9 | // target=native | |
| 10 | 8 | // |
| 11 | 9 | // :3:16: error: C pointers cannot point to opaque types |
test/cases/compile_errors/Issue_5586_Make_unary_minus_for_unsigned_types_a_compile_error.zig-2| ... | ... | @@ -8,8 +8,6 @@ export fn f2(x: @Vector(4, u32)) @Vector(4, u32) { |
| 8 | 8 | } |
| 9 | 9 | |
| 10 | 10 | // error |
| 11 | // backend=stage2 | |
| 12 | // target=native | |
| 13 | 11 | // |
| 14 | 12 | // :3:12: error: negation of type 'u32' |
| 15 | 13 | // :7:12: error: negation of type '@Vector(4, u32)' |
test/cases/compile_errors/Issue_6823_dont_allow_._to_be_followed_by_.zig-2| ... | ... | @@ -4,7 +4,5 @@ fn foo() void { |
| 4 | 4 | } |
| 5 | 5 | |
| 6 | 6 | // error |
| 7 | // backend=stage2 | |
| 8 | // target=native | |
| 9 | 7 | // |
| 10 | 8 | // :2:28: error: '.*' cannot be followed by '*'; are you missing a space? |
test/cases/compile_errors/access_inactive_union_field_comptime.zig-2| ... | ... | @@ -15,8 +15,6 @@ pub export fn entry1() void { |
| 15 | 15 | } |
| 16 | 16 | |
| 17 | 17 | // error |
| 18 | // backend=stage2 | |
| 19 | // target=native | |
| 20 | 18 | // |
| 21 | 19 | // :9:15: error: access of union field 'a' while field 'b' is active |
| 22 | 20 | // :2:21: note: union declared here |
test/cases/compile_errors/access_non-existent_member_of_error_set.zig-2| ... | ... | @@ -5,7 +5,5 @@ comptime { |
| 5 | 5 | } |
| 6 | 6 | |
| 7 | 7 | // error |
| 8 | // backend=stage2 | |
| 9 | // target=native | |
| 10 | 8 | // |
| 11 | 9 | // :3:18: error: no error named 'Bar' in 'error{A}' |
test/cases/compile_errors/accessing_runtime_parameter_from_outer_function.zig-2| ... | ... | @@ -13,8 +13,6 @@ export fn entry() void { |
| 13 | 13 | } |
| 14 | 14 | |
| 15 | 15 | // error |
| 16 | // backend=stage2 | |
| 17 | // target=native | |
| 18 | 16 | // |
| 19 | 17 | // :4:24: error: 'y' not accessible from inner function |
| 20 | 18 | // :3:9: note: crossed function definition here |
test/cases/compile_errors/accessing_runtime_paramter_outside_function_scope.zig-2| ... | ... | @@ -6,7 +6,5 @@ export fn entry(y: u8) void { |
| 6 | 6 | } |
| 7 | 7 | |
| 8 | 8 | // error |
| 9 | // backend=stage2 | |
| 10 | // target=native | |
| 11 | 9 | // |
| 12 | 10 | // :3:17: error: 'y' not accessible outside function scope |
test/cases/compile_errors/add_sat_on_undefined_value.zig-2| ... | ... | @@ -15,8 +15,6 @@ comptime { |
| 15 | 15 | } |
| 16 | 16 | |
| 17 | 17 | // error |
| 18 | // backend=stage2 | |
| 19 | // target=native | |
| 20 | 18 | // |
| 21 | 19 | // :6:5: error: found compile log statement |
| 22 | 20 | // |
test/cases/compile_errors/add_wrap_on_undefined_value.zig-2| ... | ... | @@ -15,8 +15,6 @@ comptime { |
| 15 | 15 | } |
| 16 | 16 | |
| 17 | 17 | // error |
| 18 | // backend=stage2 | |
| 19 | // target=native | |
| 20 | 18 | // |
| 21 | 19 | // :6:5: error: found compile log statement |
| 22 | 20 | // |
test/cases/compile_errors/addition_with_non_numbers.zig-2| ... | ... | @@ -8,7 +8,5 @@ export fn entry() usize { |
| 8 | 8 | } |
| 9 | 9 | |
| 10 | 10 | // error |
| 11 | // backend=stage2 | |
| 12 | // target=native | |
| 13 | 11 | // |
| 14 | 12 | // :4:29: error: invalid operands to binary expression: 'struct' and 'struct' |
test/cases/compile_errors/address_of_number_literal.zig-2| ... | ... | @@ -8,8 +8,6 @@ export fn entry() usize { |
| 8 | 8 | } |
| 9 | 9 | |
| 10 | 10 | // error |
| 11 | // backend=stage2 | |
| 12 | // target=native | |
| 13 | 11 | // |
| 14 | 12 | // :4:12: error: expected type '*const i32', found '*const comptime_int' |
| 15 | 13 | // :4:12: note: pointer type child 'comptime_int' cannot cast into pointer type child 'i32' |
test/cases/compile_errors/alignCast_expects_pointer_or_slice.zig-2| ... | ... | @@ -4,7 +4,5 @@ export fn entry() void { |
| 4 | 4 | } |
| 5 | 5 | |
| 6 | 6 | // error |
| 7 | // backend=stage2 | |
| 8 | // target=native | |
| 9 | 7 | // |
| 10 | 8 | // :2:41: error: expected pointer type, found 'u32' |
test/cases/compile_errors/alignOf_bad_type.zig-2| ... | ... | @@ -3,7 +3,5 @@ export fn entry() usize { |
| 3 | 3 | } |
| 4 | 4 | |
| 5 | 5 | // error |
| 6 | // backend=stage2 | |
| 7 | // target=native | |
| 8 | 6 | // |
| 9 | 7 | // :2:21: error: no align available for type 'noreturn' |
test/cases/compile_errors/align_n_expr_function_pointers_is_a_compile_error.zig-1| ... | ... | @@ -3,7 +3,6 @@ export fn foo() align(1) void { |
| 3 | 3 | } |
| 4 | 4 | |
| 5 | 5 | // error |
| 6 | // backend=stage2 | |
| 7 | 6 | // target=wasm32-freestanding-none |
| 8 | 7 | // |
| 9 | 8 | // :1:23: error: target does not support function alignment |
test/cases/compile_errors/alignment_of_enum_field_specified.zig-2| ... | ... | @@ -11,7 +11,5 @@ export fn entry1() void { |
| 11 | 11 | } |
| 12 | 12 | |
| 13 | 13 | // error |
| 14 | // backend=stage2 | |
| 15 | // target=native | |
| 16 | 14 | // |
| 17 | 15 | // :4:13: error: enum fields cannot be aligned |
test/cases/compile_errors/ambiguous_coercion_of_division_operands.zig-2| ... | ... | @@ -16,8 +16,6 @@ export fn entry4() void { |
| 16 | 16 | } |
| 17 | 17 | |
| 18 | 18 | // error |
| 19 | // backend=stage2 | |
| 20 | // target=native | |
| 21 | 19 | // |
| 22 | 20 | // :2:25: error: ambiguous coercion of division operands 'comptime_float' and 'comptime_int'; non-zero remainder '4' |
| 23 | 21 | // :6:23: error: ambiguous coercion of division operands 'comptime_int' and 'comptime_float'; non-zero remainder '4' |
test/cases/compile_errors/ambiguous_decl_reference.zig-2| ... | ... | @@ -13,8 +13,6 @@ export fn entry() void { |
| 13 | 13 | } |
| 14 | 14 | |
| 15 | 15 | // error |
| 16 | // backend=stage2 | |
| 17 | // target=native | |
| 18 | 16 | // |
| 19 | 17 | // :5:13: error: ambiguous reference |
| 20 | 18 | // :7:9: note: declared here |
test/cases/compile_errors/any_typed_null_to_any_typed_optional.zig-2| ... | ... | @@ -4,8 +4,6 @@ pub export fn entry() void { |
| 4 | 4 | } |
| 5 | 5 | |
| 6 | 6 | // error |
| 7 | // backend=stage2 | |
| 8 | // target=native | |
| 9 | 7 | // |
| 10 | 8 | // :3:9: error: expected type '?*anyopaque', found '?usize' |
| 11 | 9 | // :3:9: note: optional type child 'usize' cannot cast into optional type child '*anyopaque' |
test/cases/compile_errors/array_access_of_non_array.zig-2| ... | ... | @@ -8,8 +8,6 @@ export fn g() void { |
| 8 | 8 | } |
| 9 | 9 | |
| 10 | 10 | // error |
| 11 | // backend=stage2 | |
| 12 | // target=native | |
| 13 | 11 | // |
| 14 | 12 | // :3:8: error: type 'bool' does not support indexing |
| 15 | 13 | // :3:8: note: operand must be an array, slice, tuple, or vector |
test/cases/compile_errors/array_access_of_type.zig-2| ... | ... | @@ -4,8 +4,6 @@ export fn foo() void { |
| 4 | 4 | } |
| 5 | 5 | |
| 6 | 6 | // error |
| 7 | // backend=stage2 | |
| 8 | // target=native | |
| 9 | 7 | // |
| 10 | 8 | // :2:14: error: type 'type' does not support indexing |
| 11 | 9 | // :2:14: note: operand must be an array, slice, tuple, or vector |
test/cases/compile_errors/array_access_of_undeclared_identifier.zig-2| ... | ... | @@ -3,7 +3,5 @@ export fn f() void { |
| 3 | 3 | } |
| 4 | 4 | |
| 5 | 5 | // error |
| 6 | // backend=stage2 | |
| 7 | // target=native | |
| 8 | 6 | // |
| 9 | 7 | // :2:5: error: use of undeclared identifier 'i' |
test/cases/compile_errors/array_access_with_non_integer_index.zig-2| ... | ... | @@ -12,8 +12,6 @@ export fn g() void { |
| 12 | 12 | } |
| 13 | 13 | |
| 14 | 14 | // error |
| 15 | // backend=stage2 | |
| 16 | // target=native | |
| 17 | 15 | // |
| 18 | 16 | // :4:11: error: expected type 'usize', found 'bool' |
| 19 | 17 | // :10:15: error: expected type 'usize', found 'bool' |
test/cases/compile_errors/array_concatenation_with_wrong_type.zig-2| ... | ... | @@ -7,7 +7,5 @@ export fn entry() usize { |
| 7 | 7 | } |
| 8 | 8 | |
| 9 | 9 | // error |
| 10 | // backend=stage2 | |
| 11 | // target=native | |
| 12 | 10 | // |
| 13 | 11 | // :3:11: error: expected indexable; found 'usize' |
test/cases/compile_errors/array_init_invalid_elem_count.zig-2| ... | ... | @@ -32,8 +32,6 @@ export fn entry3() void { |
| 32 | 32 | } |
| 33 | 33 | |
| 34 | 34 | // error |
| 35 | // backend=stage2 | |
| 36 | // target=native | |
| 37 | 35 | // |
| 38 | 36 | // :4:17: error: expected 8 vector elements; found 1 |
| 39 | 37 | // :8:17: error: expected 8 vector elements; found 0 |
test/cases/compile_errors/array_init_not_supported_on_result_type.zig-2| ... | ... | @@ -5,7 +5,5 @@ export fn foo() void { |
| 5 | 5 | } |
| 6 | 6 | |
| 7 | 7 | // error |
| 8 | // backend=stage2 | |
| 9 | // target=native | |
| 10 | 8 | // |
| 11 | 9 | // :4:12: error: type 'u32' does not support array initialization syntax |
test/cases/compile_errors/asm_at_compile_time.zig-2| ... | ... | @@ -11,8 +11,6 @@ fn doSomeAsm() void { |
| 11 | 11 | } |
| 12 | 12 | |
| 13 | 13 | // error |
| 14 | // backend=stage2 | |
| 15 | // target=native | |
| 16 | 14 | // |
| 17 | 15 | // :6:5: error: unable to evaluate comptime expression |
| 18 | 16 | // :2:14: note: called at comptime from here |
test/cases/compile_errors/asm_output_to_const.zig-2| ... | ... | @@ -8,7 +8,5 @@ export fn foo() void { |
| 8 | 8 | } |
| 9 | 9 | |
| 10 | 10 | // error |
| 11 | // backend=stage2 | |
| 12 | // target=native | |
| 13 | 11 | // |
| 14 | 12 | // :4:5: error: asm cannot output to const local 'f' |
test/cases/compile_errors/assign_inline_fn_to_non-comptime_var.zig-2| ... | ... | @@ -5,8 +5,6 @@ export fn entry() void { |
| 5 | 5 | inline fn b() void {} |
| 6 | 6 | |
| 7 | 7 | // error |
| 8 | // backend=stage2 | |
| 9 | // target=native | |
| 10 | 8 | // |
| 11 | 9 | // :2:9: error: variable of type '*const fn () callconv(.@"inline") void' must be const or comptime |
| 12 | 10 | // :2:9: note: function has inline calling convention |
test/cases/compile_errors/assign_local_bad_coercion.zig-2| ... | ... | @@ -13,8 +13,6 @@ export fn varEntry() u32 { |
| 13 | 13 | } |
| 14 | 14 | |
| 15 | 15 | // error |
| 16 | // backend=stage2 | |
| 17 | // target=native | |
| 18 | 16 | // |
| 19 | 17 | // :6:21: error: expected type 'u32', found 'u64' |
| 20 | 18 | // :6:21: note: unsigned 32-bit int cannot represent all possible unsigned 64-bit values |
test/cases/compile_errors/assign_null_to_non-optional_pointer.zig-2| ... | ... | @@ -5,7 +5,5 @@ export fn entry() usize { |
| 5 | 5 | } |
| 6 | 6 | |
| 7 | 7 | // error |
| 8 | // backend=stage2 | |
| 9 | // target=native | |
| 10 | 8 | // |
| 11 | 9 | // :1:16: error: expected type '*u8', found '@TypeOf(null)' |
test/cases/compile_errors/assign_through_constant_pointer.zig-2| ... | ... | @@ -4,7 +4,5 @@ export fn f() void { |
| 4 | 4 | } |
| 5 | 5 | |
| 6 | 6 | // error |
| 7 | // backend=stage2 | |
| 8 | // target=native | |
| 9 | 7 | // |
| 10 | 8 | // :3:9: error: cannot assign to constant |
test/cases/compile_errors/assign_through_constant_slice.zig-2| ... | ... | @@ -4,7 +4,5 @@ export fn f() void { |
| 4 | 4 | } |
| 5 | 5 | |
| 6 | 6 | // error |
| 7 | // backend=stage2 | |
| 8 | // target=native | |
| 9 | 7 | // |
| 10 | 8 | // :3:9: error: cannot assign to constant |
test/cases/compile_errors/assign_to_constant_field.zig-2| ... | ... | @@ -9,7 +9,5 @@ export fn derp() void { |
| 9 | 9 | } |
| 10 | 10 | |
| 11 | 11 | // error |
| 12 | // backend=stage2 | |
| 13 | // target=native | |
| 14 | 12 | // |
| 15 | 13 | // :8:6: error: cannot assign to constant |
test/cases/compile_errors/assign_to_invalid_dereference.zig-2| ... | ... | @@ -3,7 +3,5 @@ export fn entry() void { |
| 3 | 3 | } |
| 4 | 4 | |
| 5 | 5 | // error |
| 6 | // backend=stage2 | |
| 7 | // target=native | |
| 8 | 6 | // |
| 9 | 7 | // :2:8: error: cannot dereference non-pointer type 'comptime_int' |
test/cases/compile_errors/assign_too_big_number_to_u16.zig-2| ... | ... | @@ -4,7 +4,5 @@ export fn foo() void { |
| 4 | 4 | } |
| 5 | 5 | |
| 6 | 6 | // error |
| 7 | // backend=stage2 | |
| 8 | // target=native | |
| 9 | 7 | // |
| 10 | 8 | // :2:26: error: type 'u16' cannot represent integer value '753664' |
test/cases/compile_errors/assign_unreachable.zig-2| ... | ... | @@ -4,8 +4,6 @@ export fn f() void { |
| 4 | 4 | } |
| 5 | 5 | |
| 6 | 6 | // error |
| 7 | // backend=stage2 | |
| 8 | // target=native | |
| 9 | 7 | // |
| 10 | 8 | // :2:5: error: unreachable code |
| 11 | 9 | // :2:15: note: control flow is diverted here |
test/cases/compile_errors/assigning_to_struct_or_union_fields_that_are_not_optionals_with_a_function_that_returns_an_optional.zig-2| ... | ... | @@ -15,8 +15,6 @@ export fn entry() void { |
| 15 | 15 | } |
| 16 | 16 | |
| 17 | 17 | // error |
| 18 | // backend=stage2 | |
| 19 | // target=native | |
| 20 | 18 | // |
| 21 | 19 | // :11:20: error: expected type 'u8', found '?u8' |
| 22 | 20 | // :11:20: note: cannot convert optional to payload type |
test/cases/compile_errors/atomic_orderings_of_atomicStore_Acquire_or_AcqRel.zig-2| ... | ... | @@ -4,7 +4,5 @@ export fn entry() void { |
| 4 | 4 | } |
| 5 | 5 | |
| 6 | 6 | // error |
| 7 | // backend=stage2 | |
| 8 | // target=native | |
| 9 | 7 | // |
| 10 | 8 | // :3:31: error: @atomicStore atomic ordering must not be acquire or acq_rel |
test/cases/compile_errors/atomic_orderings_of_cmpxchg-failure_stricter_than_success.zig-2| ... | ... | @@ -5,7 +5,5 @@ export fn f() void { |
| 5 | 5 | } |
| 6 | 6 | |
| 7 | 7 | // error |
| 8 | // backend=stage2 | |
| 9 | // target=native | |
| 10 | 8 | // |
| 11 | 9 | // :4:81: error: failure atomic ordering must be no stricter than success |
test/cases/compile_errors/atomic_orderings_of_cmpxchg-success_Monotonic_or_stricter.zig-2| ... | ... | @@ -5,7 +5,5 @@ export fn f() void { |
| 5 | 5 | } |
| 6 | 6 | |
| 7 | 7 | // error |
| 8 | // backend=stage2 | |
| 9 | // target=native | |
| 10 | 8 | // |
| 11 | 9 | // :4:58: error: success atomic ordering must be monotonic or stricter |
test/cases/compile_errors/atomicrmw_with_bool_op_not_.Xchg.zig-2| ... | ... | @@ -4,7 +4,5 @@ export fn entry() void { |
| 4 | 4 | } |
| 5 | 5 | |
| 6 | 6 | // error |
| 7 | // backend=stage2 | |
| 8 | // target=native | |
| 9 | 7 | // |
| 10 | 8 | // :3:31: error: @atomicRmw with bool only allowed with .Xchg |
test/cases/compile_errors/atomicrmw_with_enum_op_not_.Xchg.zig-2| ... | ... | @@ -10,7 +10,5 @@ export fn entry() void { |
| 10 | 10 | } |
| 11 | 11 | |
| 12 | 12 | // error |
| 13 | // backend=stage2 | |
| 14 | // target=native | |
| 15 | 13 | // |
| 16 | 14 | // :9:28: error: @atomicRmw with enum only allowed with .Xchg |
test/cases/compile_errors/atomicrmw_with_float_op_not_.Xchg_.Add_.Sub_.Max_or_.Min.zig-2| ... | ... | @@ -4,7 +4,5 @@ export fn entry() void { |
| 4 | 4 | } |
| 5 | 5 | |
| 6 | 6 | // error |
| 7 | // backend=stage2 | |
| 8 | // target=native | |
| 9 | 7 | // |
| 10 | 8 | // :3:30: error: @atomicRmw with float only allowed with .Xchg, .Add, .Sub, .Max, and .Min |
test/cases/compile_errors/atomics_with_invalid_type.zig-2| ... | ... | @@ -21,8 +21,6 @@ export fn errorSet() void { |
| 21 | 21 | } |
| 22 | 22 | |
| 23 | 23 | // error |
| 24 | // backend=stage2 | |
| 25 | // target=native | |
| 26 | 24 | // |
| 27 | 25 | // :3:22: error: expected bool, integer, enum, packed struct, or pointer type; found 'f32' |
| 28 | 26 | // :9:22: error: expected bool, integer, float, enum, packed struct, or pointer type; found 'tmp.NormalStruct' |
test/cases/compile_errors/attempt_to_cast_enum_literal_to_error.zig-2| ... | ... | @@ -5,7 +5,5 @@ export fn entry() void { |
| 5 | 5 | } |
| 6 | 6 | |
| 7 | 7 | // error |
| 8 | // backend=stage2 | |
| 9 | // target=native | |
| 10 | 8 | // |
| 11 | 9 | // :3:10: error: expected type 'error{Hi}', found '@Type(.enum_literal)' |
test/cases/compile_errors/attempt_to_close_over_comptime_variable_from_outer_scope.zig-2| ... | ... | @@ -6,8 +6,6 @@ fn SimpleList(comptime L: usize) type { |
| 6 | 6 | } |
| 7 | 7 | |
| 8 | 8 | // error |
| 9 | // backend=stage2 | |
| 10 | // target=native | |
| 11 | 9 | // |
| 12 | 10 | // :4:19: error: mutable 'T' not accessible from here |
| 13 | 11 | // :2:9: note: declared mutable here |
test/cases/compile_errors/attempt_to_create_17_bit_float_type.zig-2| ... | ... | @@ -4,7 +4,5 @@ comptime { |
| 4 | 4 | } |
| 5 | 5 | |
| 6 | 6 | // error |
| 7 | // backend=stage2 | |
| 8 | // target=native | |
| 9 | 7 | // |
| 10 | 8 | // :3:9: error: 17-bit float unsupported |
test/cases/compile_errors/attempt_to_negate_a_non-integer_non-float_or_non-vector_type.zig-2| ... | ... | @@ -8,7 +8,5 @@ export fn entry() void { |
| 8 | 8 | } |
| 9 | 9 | |
| 10 | 10 | // error |
| 11 | // backend=stage2 | |
| 12 | // target=native | |
| 13 | 11 | // |
| 14 | 12 | // :6:15: error: negation of type 'anyerror!u32' |
test/cases/compile_errors/attempted_double_ampersand.zig-2| ... | ... | @@ -6,7 +6,5 @@ export fn entry(a: bool, b: bool) i32 { |
| 6 | 6 | } |
| 7 | 7 | |
| 8 | 8 | // error |
| 9 | // backend=stage2 | |
| 10 | // target=native | |
| 11 | 9 | // |
| 12 | 10 | // :2:11: error: ambiguous use of '&&'; use 'and' for logical AND, or change whitespace to ' & &' for bitwise AND |
test/cases/compile_errors/attempted_implicit_cast_from_T_to_long_array_ptr.zig-2| ... | ... | @@ -9,8 +9,6 @@ export fn entry2(single: *u32) void { |
| 9 | 9 | } |
| 10 | 10 | |
| 11 | 11 | // error |
| 12 | // backend=stage2 | |
| 13 | // target=native | |
| 14 | 12 | // |
| 15 | 13 | // :2:28: error: expected type '*const [0]u32', found '*u32' |
| 16 | 14 | // :2:28: note: pointer type child 'u32' cannot cast into pointer type child '[0]u32' |
test/cases/compile_errors/attempted_implicit_cast_from_T_to_slice_const_T.zig-2| ... | ... | @@ -4,7 +4,5 @@ export fn entry() void { |
| 4 | 4 | } |
| 5 | 5 | |
| 6 | 6 | // error |
| 7 | // backend=stage2 | |
| 8 | // target=native | |
| 9 | 7 | // |
| 10 | 8 | // :2:30: error: expected type '[*]const bool', found 'bool' |
test/cases/compile_errors/attempted_implicit_cast_from_const_T_to_array_len_1_T.zig-2| ... | ... | @@ -7,8 +7,6 @@ export fn entry() void { |
| 7 | 7 | } |
| 8 | 8 | |
| 9 | 9 | // error |
| 10 | // backend=stage2 | |
| 11 | // target=native | |
| 12 | 10 | // |
| 13 | 11 | // :4:22: error: expected type '*[1]i32', found '*const i32' |
| 14 | 12 | // :4:22: note: cast discards const qualifier |
test/cases/compile_errors/attempted_implicit_cast_from_const_T_to_sliceT.zig-2| ... | ... | @@ -5,8 +5,6 @@ export fn entry() void { |
| 5 | 5 | } |
| 6 | 6 | |
| 7 | 7 | // error |
| 8 | // backend=stage2 | |
| 9 | // target=native | |
| 10 | 8 | // |
| 11 | 9 | // :3:22: error: expected type '[]u32', found '*const u32' |
| 12 | 10 | // :3:22: note: cast discards const qualifier |
test/cases/compile_errors/bad_alignCast_at_comptime.zig-2| ... | ... | @@ -5,7 +5,5 @@ comptime { |
| 5 | 5 | } |
| 6 | 6 | |
| 7 | 7 | // error |
| 8 | // backend=stage2 | |
| 9 | // target=native | |
| 10 | 8 | // |
| 11 | 9 | // :3:47: error: pointer address 0x1 is not aligned to 4 bytes |
test/cases/compile_errors/bad_alignment_in_implicit_cast_from_array_pointer_to_slice.zig-2| ... | ... | @@ -5,8 +5,6 @@ export fn a() void { |
| 5 | 5 | } |
| 6 | 6 | |
| 7 | 7 | // error |
| 8 | // backend=stage2 | |
| 9 | // target=native | |
| 10 | 8 | // |
| 11 | 9 | // :3:31: error: expected type '[]align(16) u8', found '*[10]u8' |
| 12 | 10 | // :3:31: note: pointer alignment '1' cannot cast into pointer alignment '16' |
test/cases/compile_errors/bad_alignment_type.zig-2| ... | ... | @@ -8,8 +8,6 @@ export fn entry2() void { |
| 8 | 8 | } |
| 9 | 9 | |
| 10 | 10 | // error |
| 11 | // backend=stage2 | |
| 12 | // target=native | |
| 13 | 11 | // |
| 14 | 12 | // :2:22: error: expected type 'u29', found 'bool' |
| 15 | 13 | // :6:21: error: fractional component prevents float value '12.34' from coercion to type 'u29' |
test/cases/compile_errors/bad_identifier_in_function_with_struct_defined_inside_function_which_references_local_const.zig-2| ... | ... | @@ -11,7 +11,5 @@ export fn entry() void { |
| 11 | 11 | } |
| 12 | 12 | |
| 13 | 13 | // error |
| 14 | // backend=stage2 | |
| 15 | // target=native | |
| 16 | 14 | // |
| 17 | 15 | // :8:5: error: use of undeclared identifier 'bogus' |
test/cases/compile_errors/bad_inferred_variable_type.zig created+9| ... | ... | @@ -0,0 +1,9 @@ |
| 1 | pub fn main() void { | |
| 2 | var x = null; | |
| 3 | _ = &x; | |
| 4 | } | |
| 5 | ||
| 6 | // error | |
| 7 | // output_mode=Exe | |
| 8 | // | |
| 9 | // :2:9: error: variable of type '@TypeOf(null)' must be const or comptime |
test/cases/compile_errors/bad_member_access_on_tuple.zig-2| ... | ... | @@ -3,7 +3,5 @@ comptime { |
| 3 | 3 | } |
| 4 | 4 | |
| 5 | 5 | // error |
| 6 | // backend=stage2 | |
| 7 | // target=native | |
| 8 | 6 | // |
| 9 | 7 | // :2:21: error: struct '@TypeOf(.{})' has no member named 'is_optional' |
test/cases/compile_errors/bad_usage_of_call.zig-2| ... | ... | @@ -36,8 +36,6 @@ noinline fn dummy() u32 { |
| 36 | 36 | noinline fn dummy2() void {} |
| 37 | 37 | |
| 38 | 38 | // error |
| 39 | // backend=stage2 | |
| 40 | // target=native | |
| 41 | 39 | // |
| 42 | 40 | // :2:23: error: expected a tuple, found 'void' |
| 43 | 41 | // :5:21: error: unable to perform 'never_inline' call at compile-time |
test/cases/compile_errors/binary_OR_operator_on_error_sets.zig-2| ... | ... | @@ -6,7 +6,5 @@ export fn entry() void { |
| 6 | 6 | } |
| 7 | 7 | |
| 8 | 8 | // error |
| 9 | // backend=stage2 | |
| 10 | // target=native | |
| 11 | 9 | // |
| 12 | 10 | // :2:18: error: invalid operands to binary bitwise expression: 'error_set' and 'error_set' |
test/cases/compile_errors/binary_not_on_number_literal.zig-2| ... | ... | @@ -7,7 +7,5 @@ export fn entry() usize { |
| 7 | 7 | } |
| 8 | 8 | |
| 9 | 9 | // error |
| 10 | // backend=stage2 | |
| 11 | // target=native | |
| 12 | 10 | // |
| 13 | 11 | // :3:61: error: bitwise not operation on type 'comptime_int' |
test/cases/compile_errors/bitCast_same_size_but_bit_count_mismatch.zig-2| ... | ... | @@ -4,7 +4,5 @@ export fn entry(byte: u8) void { |
| 4 | 4 | } |
| 5 | 5 | |
| 6 | 6 | // error |
| 7 | // backend=stage2 | |
| 8 | // target=native | |
| 9 | 7 | // |
| 10 | 8 | // :2:22: error: @bitCast size mismatch: destination type 'u7' has 7 bits but source type 'u8' has 8 bits |
test/cases/compile_errors/bitCast_to_enum_type.zig-2| ... | ... | @@ -5,8 +5,6 @@ export fn entry() void { |
| 5 | 5 | } |
| 6 | 6 | |
| 7 | 7 | // error |
| 8 | // backend=stage2 | |
| 9 | // target=native | |
| 10 | 8 | // |
| 11 | 9 | // :3:18: error: cannot @bitCast to 'tmp.entry.E' |
| 12 | 10 | // :3:18: note: use @enumFromInt to cast from 'u32' |
test/cases/compile_errors/bitCast_with_different_sizes_inside_an_expression.zig-2| ... | ... | @@ -5,7 +5,5 @@ export fn entry() void { |
| 5 | 5 | } |
| 6 | 6 | |
| 7 | 7 | // error |
| 8 | // backend=stage2 | |
| 9 | // target=native | |
| 10 | 8 | // |
| 11 | 9 | // :3:26: error: @bitCast size mismatch: destination type 'u8' has 8 bits but source type 'f32' has 32 bits |
test/cases/compile_errors/bit_shifting_only_works_on_integer_types.zig-2| ... | ... | @@ -4,7 +4,5 @@ export fn entry() void { |
| 4 | 4 | } |
| 5 | 5 | |
| 6 | 6 | // error |
| 7 | // backend=stage2 | |
| 8 | // target=native | |
| 9 | 7 | // |
| 10 | 8 | // :2:15: error: bit shifting operation expected integer type, found '*const u8' |
test/cases/compile_errors/bitsize_of_packed_struct_checks_backing_int_ty.zig-2| ... | ... | @@ -7,7 +7,5 @@ pub export fn entry() void { |
| 7 | 7 | } |
| 8 | 8 | |
| 9 | 9 | // error |
| 10 | // backend=stage2 | |
| 11 | // target=native | |
| 12 | 10 | // |
| 13 | 11 | // :1:27: error: backing integer type 'u32' has bit size 32 but the struct fields have a total bit size of 1 |
test/cases/compile_errors/bogus_compile_var.zig-2| ... | ... | @@ -4,8 +4,6 @@ export fn entry() usize { |
| 4 | 4 | } |
| 5 | 5 | |
| 6 | 6 | // error |
| 7 | // backend=stage2 | |
| 8 | // target=native | |
| 9 | 7 | // |
| 10 | 8 | // :1:29: error: root source file struct 'builtin' has no member named 'bogus' |
| 11 | 9 | // note: struct declared here |
test/cases/compile_errors/bool_not_on_vector_of_ints.zig-2| ... | ... | @@ -4,7 +4,5 @@ export fn foo() void { |
| 4 | 4 | } |
| 5 | 5 | |
| 6 | 6 | // error |
| 7 | // backend=stage2 | |
| 8 | // target=native | |
| 9 | 7 | // |
| 10 | 8 | // :3:10: error: boolean not operation on type '@Vector(2, u1)' |
test/cases/compile_errors/break_void_result_location.zig-2| ... | ... | @@ -24,8 +24,6 @@ export fn f4() void { |
| 24 | 24 | } |
| 25 | 25 | |
| 26 | 26 | // error |
| 27 | // backend=stage2 | |
| 28 | // target=native | |
| 29 | 27 | // |
| 30 | 28 | // :2:22: error: expected type 'usize', found 'void' |
| 31 | 29 | // :7:9: error: expected type 'usize', found 'void' |
test/cases/compile_errors/builtin_call_with_invalid_param.zig-2| ... | ... | @@ -5,8 +5,6 @@ export fn builtinCallBoolFunctionInlineWithVoid() void { |
| 5 | 5 | fn boolFunction(_: bool) void {} |
| 6 | 6 | |
| 7 | 7 | // error |
| 8 | // backend=stage2 | |
| 9 | // target=native | |
| 10 | 8 | // |
| 11 | 9 | // :2:43: error: expected type 'bool', found 'void' |
| 12 | 10 | // :5:20: note: parameter type declared here |
test/cases/compile_errors/c_pointer_to_void.zig-2| ... | ... | @@ -4,8 +4,6 @@ export fn entry() void { |
| 4 | 4 | } |
| 5 | 5 | |
| 6 | 6 | // error |
| 7 | // backend=stage2 | |
| 8 | // target=native | |
| 9 | 7 | // |
| 10 | 8 | // :2:18: error: C pointers cannot point to non-C-ABI-compatible type 'void' |
| 11 | 9 | // :2:18: note: 'void' is a zero bit type; for C 'void' use 'anyopaque' |
test/cases/compile_errors/call_assigned_to_constant.zig-2| ... | ... | @@ -17,8 +17,6 @@ export fn entry1() void { |
| 17 | 17 | } |
| 18 | 18 | |
| 19 | 19 | // error |
| 20 | // backend=stage2 | |
| 21 | // target=native | |
| 22 | 20 | // |
| 23 | 21 | // :12:5: error: cannot assign to constant |
| 24 | 22 | // :16:5: error: cannot assign to constant |
test/cases/compile_errors/call_from_double_ptr.zig-2| ... | ... | @@ -7,8 +7,6 @@ export fn entry(a: **S) void { |
| 7 | 7 | } |
| 8 | 8 | |
| 9 | 9 | // error |
| 10 | // backend=stage2 | |
| 11 | // target=native | |
| 12 | 10 | // |
| 13 | 11 | // 6:10: error: no field or member function named 'b' in '*tmp.S' |
| 14 | 12 | // 6:10: note: method invocation only supports up to one level of implicit pointer dereferencing |
test/cases/compile_errors/call_from_naked_func.zig-2| ... | ... | @@ -17,8 +17,6 @@ export fn comptimeBuiltinCall() callconv(.naked) void { |
| 17 | 17 | fn f() void {} |
| 18 | 18 | |
| 19 | 19 | // error |
| 20 | // backend=stage2 | |
| 21 | // target=native | |
| 22 | 20 | // |
| 23 | 21 | // :2:6: error: runtime call not allowed in naked function |
| 24 | 22 | // :6:5: error: runtime @call not allowed in naked function |
test/cases/compile_errors/call_optional_function.zig-2| ... | ... | @@ -8,8 +8,6 @@ pub export fn entry2() void { |
| 8 | 8 | } |
| 9 | 9 | |
| 10 | 10 | // error |
| 11 | // backend=stage2 | |
| 12 | // target=native | |
| 13 | 11 | // |
| 14 | 12 | // :3:9: error: cannot call optional type '?fn () void' |
| 15 | 13 | // :3:9: note: consider using '.?', 'orelse' or 'if' |
test/cases/compile_errors/callconv_from_global_variable.zig-2| ... | ... | @@ -2,8 +2,6 @@ var cc: @import("std").builtin.CallingConvention = .c; |
| 2 | 2 | export fn foo() callconv(cc) void {} |
| 3 | 3 | |
| 4 | 4 | // error |
| 5 | // backend=stage2 | |
| 6 | // target=native | |
| 7 | 5 | // |
| 8 | 6 | // :2:26: error: unable to resolve comptime value |
| 9 | 7 | // :2:26: note: calling convention must be comptime-known |
test/cases/compile_errors/callconv_interrupt_on_unsupported_platform.zig-1| ... | ... | @@ -3,7 +3,6 @@ export fn entry2() callconv(.{ .x86_interrupt = .{} }) void {} |
| 3 | 3 | export fn entry3() callconv(.avr_interrupt) void {} |
| 4 | 4 | |
| 5 | 5 | // error |
| 6 | // backend=stage2 | |
| 7 | 6 | // target=aarch64-linux-none |
| 8 | 7 | // |
| 9 | 8 | // :1:30: error: calling convention 'x86_64_interrupt' only available on architectures 'x86_64' |
test/cases/compile_errors/callconv_signal_on_unsupported_platform.zig-1| ... | ... | @@ -1,7 +1,6 @@ |
| 1 | 1 | export fn entry() callconv(.avr_signal) void {} |
| 2 | 2 | |
| 3 | 3 | // error |
| 4 | // backend=stage2 | |
| 5 | 4 | // target=x86_64-linux-none |
| 6 | 5 | // |
| 7 | 6 | // :1:29: error: calling convention 'avr_signal' only available on architectures 'avr' |
test/cases/compile_errors/callconv_stdcall_fastcall_thiscall_on_unsupported_platform.zig-1| ... | ... | @@ -15,7 +15,6 @@ export fn entry3() void { |
| 15 | 15 | } |
| 16 | 16 | |
| 17 | 17 | // error |
| 18 | // backend=stage2 | |
| 19 | 18 | // target=x86_64-linux-none |
| 20 | 19 | // |
| 21 | 20 | // :1:28: error: calling convention 'x86_stdcall' only available on architectures 'x86' |
test/cases/compile_errors/calling_function_with_naked_calling_convention.zig-2| ... | ... | @@ -4,8 +4,6 @@ export fn entry() void { |
| 4 | 4 | fn foo() callconv(.naked) void {} |
| 5 | 5 | |
| 6 | 6 | // error |
| 7 | // backend=stage2 | |
| 8 | // target=native | |
| 9 | 7 | // |
| 10 | 8 | // :2:5: error: unable to call function with calling convention 'naked' |
| 11 | 9 | // :4:1: note: function declared here |
test/cases/compile_errors/calling_var_args_extern_function_passing_array_instead_of_pointer.zig-2| ... | ... | @@ -6,8 +6,6 @@ export fn entry() void { |
| 6 | 6 | pub extern fn foo(format: *const u8, ...) void; |
| 7 | 7 | |
| 8 | 8 | // error |
| 9 | // backend=stage2 | |
| 10 | // target=native | |
| 11 | 9 | // |
| 12 | 10 | // :3:16: error: expected type '*const u8', found '[5:0]u8' |
| 13 | 11 | // :6:27: note: parameter type declared here |
test/cases/compile_errors/cannot_break_out_of_defer_expression.zig-2| ... | ... | @@ -7,8 +7,6 @@ export fn foo() void { |
| 7 | 7 | } |
| 8 | 8 | |
| 9 | 9 | // error |
| 10 | // backend=stage2 | |
| 11 | // target=native | |
| 12 | 10 | // |
| 13 | 11 | // :4:13: error: cannot break out of defer expression |
| 14 | 12 | // :3:9: note: defer expression here |
test/cases/compile_errors/cannot_continue_out_of_defer_expression.zig-2| ... | ... | @@ -7,8 +7,6 @@ export fn foo() void { |
| 7 | 7 | } |
| 8 | 8 | |
| 9 | 9 | // error |
| 10 | // backend=stage2 | |
| 11 | // target=native | |
| 12 | 10 | // |
| 13 | 11 | // :4:13: error: cannot continue out of defer expression |
| 14 | 12 | // :3:9: note: defer expression here |
test/cases/compile_errors/capture_by_ref_discard.zig-2| ... | ... | @@ -17,8 +17,6 @@ export fn d() void { |
| 17 | 17 | } |
| 18 | 18 | |
| 19 | 19 | // error |
| 20 | // backend=stage2 | |
| 21 | // target=native | |
| 22 | 20 | // |
| 23 | 21 | // :2:16: error: pointer modifier invalid on discard |
| 24 | 22 | // :7:18: error: pointer modifier invalid on discard |
test/cases/compile_errors/capture_by_ref_if.zig-2| ... | ... | @@ -3,8 +3,6 @@ test { |
| 3 | 3 | } |
| 4 | 4 | |
| 5 | 5 | // error |
| 6 | // backend=stage2 | |
| 7 | // target=native | |
| 8 | 6 | // |
| 9 | 7 | // :2:22: error: unused capture |
| 10 | 8 | // :2:38: error: unused capture |
test/cases/compile_errors/capture_by_ref_if_err_switch.zig-2| ... | ... | @@ -4,7 +4,5 @@ test { |
| 4 | 4 | } |
| 5 | 5 | |
| 6 | 6 | // error |
| 7 | // backend=stage2 | |
| 8 | // target=native | |
| 9 | 7 | // |
| 10 | 8 | // :3:14: error: unused capture |
test/cases/compile_errors/capture_by_ref_switch.zig-2| ... | ... | @@ -5,7 +5,5 @@ test { |
| 5 | 5 | } |
| 6 | 6 | |
| 7 | 7 | // error |
| 8 | // backend=stage2 | |
| 9 | // target=native | |
| 10 | 8 | // |
| 11 | 9 | // :3:17: error: unused capture |
test/cases/compile_errors/capture_by_ref_while.zig-2| ... | ... | @@ -3,8 +3,6 @@ test { |
| 3 | 3 | } |
| 4 | 4 | |
| 5 | 5 | // error |
| 6 | // backend=stage2 | |
| 7 | // target=native | |
| 8 | 6 | // |
| 9 | 7 | // :2:25: error: unused capture |
| 10 | 8 | // :2:39: error: unused capture |
test/cases/compile_errors/cast_between_optional_T_where_T_is_not_a_pointer.zig-2| ... | ... | @@ -16,8 +16,6 @@ export fn entry2() void { |
| 16 | 16 | } |
| 17 | 17 | |
| 18 | 18 | // error |
| 19 | // backend=stage2 | |
| 20 | // target=native | |
| 21 | 19 | // |
| 22 | 20 | // :6:9: error: expected type '?*const fn (i8) void', found '?*const fn (u64) void' |
| 23 | 21 | // :6:9: note: pointer type child 'fn (u64) void' cannot cast into pointer type child 'fn (i8) void' |
test/cases/compile_errors/cast_enum_literal_to_enum_but_it_doesnt_match.zig-2| ... | ... | @@ -8,8 +8,6 @@ export fn entry() void { |
| 8 | 8 | } |
| 9 | 9 | |
| 10 | 10 | // error |
| 11 | // backend=stage2 | |
| 12 | // target=native | |
| 13 | 11 | // |
| 14 | 12 | // :6:21: error: enum 'tmp.Foo' has no member named 'c' |
| 15 | 13 | // :1:13: note: enum declared here |
test/cases/compile_errors/cast_error_union_of_global_error_set_to_error_union_of_smaller_error_set.zig-2| ... | ... | @@ -8,8 +8,6 @@ fn foo() anyerror!i32 { |
| 8 | 8 | } |
| 9 | 9 | |
| 10 | 10 | // error |
| 11 | // backend=stage2 | |
| 12 | // target=native | |
| 13 | 11 | // |
| 14 | 12 | // :3:37: error: expected type 'error{A}!i32', found 'anyerror!i32' |
| 15 | 13 | // :3:37: note: global error set cannot cast into a smaller set |
test/cases/compile_errors/cast_global_error_set_to_error_set.zig-2| ... | ... | @@ -8,8 +8,6 @@ fn foo() anyerror { |
| 8 | 8 | } |
| 9 | 9 | |
| 10 | 10 | // error |
| 11 | // backend=stage2 | |
| 12 | // target=native | |
| 13 | 11 | // |
| 14 | 12 | // :3:33: error: expected type 'error{A}', found 'anyerror' |
| 15 | 13 | // :3:33: note: global error set cannot cast into a smaller set |
test/cases/compile_errors/cast_negative_integer_literal_to_usize.zig-2| ... | ... | @@ -8,8 +8,6 @@ export fn entry1() void { |
| 8 | 8 | } |
| 9 | 9 | |
| 10 | 10 | // error |
| 11 | // backend=stage2 | |
| 12 | // target=native | |
| 13 | 11 | // |
| 14 | 12 | // :2:26: error: type 'usize' cannot represent integer value '-10' |
| 15 | 13 | // :6:26: error: float value '-10' cannot be stored in integer type 'usize' |
test/cases/compile_errors/cast_negative_value_to_unsigned_integer.zig-2| ... | ... | @@ -10,8 +10,6 @@ export fn entry1() void { |
| 10 | 10 | } |
| 11 | 11 | |
| 12 | 12 | // error |
| 13 | // backend=stage2 | |
| 14 | // target=native | |
| 15 | 13 | // |
| 16 | 14 | // :3:36: error: type 'u32' cannot represent integer value '-1' |
| 17 | 15 | // :8:27: error: type 'u32' cannot represent integer value '-1' |
test/cases/compile_errors/cast_unreachable.zig-2| ... | ... | @@ -6,8 +6,6 @@ export fn entry() void { |
| 6 | 6 | } |
| 7 | 7 | |
| 8 | 8 | // error |
| 9 | // backend=stage2 | |
| 10 | // target=native | |
| 11 | 9 | // |
| 12 | 10 | // :2:12: error: unreachable code |
| 13 | 11 | // :2:21: note: control flow is diverted here |
test/cases/compile_errors/cast_without_result_type.zig-2| ... | ... | @@ -19,8 +19,6 @@ export fn e() void { |
| 19 | 19 | } |
| 20 | 20 | |
| 21 | 21 | // error |
| 22 | // backend=stage2 | |
| 23 | // target=native | |
| 24 | 22 | // |
| 25 | 23 | // :2:9: error: @ptrFromInt must have a known result type |
| 26 | 24 | // :2:9: note: use @as to provide explicit result type |
test/cases/compile_errors/cast_without_result_type_due_to_anyopaque_pointer.zig-2| ... | ... | @@ -10,8 +10,6 @@ export fn bar() void { |
| 10 | 10 | } |
| 11 | 11 | |
| 12 | 12 | // error |
| 13 | // backend=stage2 | |
| 14 | // target=native | |
| 15 | 13 | // |
| 16 | 14 | // :2:34: error: @intCast must have a known result type |
| 17 | 15 | // :2:34: note: result type is unknown due to opaque pointer type |
test/cases/compile_errors/cast_without_result_type_due_to_generic_parameter.zig-2| ... | ... | @@ -19,8 +19,6 @@ export fn f() void { |
| 19 | 19 | fn bar(_: anytype) void {} |
| 20 | 20 | |
| 21 | 21 | // error |
| 22 | // backend=stage2 | |
| 23 | // target=native | |
| 24 | 22 | // |
| 25 | 23 | // :2:9: error: @ptrFromInt must have a known result type |
| 26 | 24 | // :2:8: note: result type is unknown due to anytype parameter |
test/cases/compile_errors/casting_bit_offset_pointer_to_regular_pointer.zig-2| ... | ... | @@ -17,8 +17,6 @@ export fn entry() usize { |
| 17 | 17 | } |
| 18 | 18 | |
| 19 | 19 | // error |
| 20 | // backend=stage2 | |
| 21 | // target=native | |
| 22 | 20 | // |
| 23 | 21 | // :8:16: error: expected type '*const u3', found '*align(1:3:1) const u3' |
| 24 | 22 | // :8:16: note: pointer host size '1' cannot cast into pointer host size '0' |
test/cases/compile_errors/chained_comparison_operators.zig-2| ... | ... | @@ -3,7 +3,5 @@ export fn a(value: u32) bool { |
| 3 | 3 | } |
| 4 | 4 | |
| 5 | 5 | // error |
| 6 | // backend=stage2 | |
| 7 | // target=native | |
| 8 | 6 | // |
| 9 | 7 | // :2:22: error: comparison operators cannot be chained |
test/cases/compile_errors/cimport.zig-2| ... | ... | @@ -7,8 +7,6 @@ const d = @cImport({ |
| 7 | 7 | }); |
| 8 | 8 | |
| 9 | 9 | // error |
| 10 | // backend=stage2 | |
| 11 | // target=native | |
| 12 | 10 | // |
| 13 | 11 | // :1:11: error: C define valid only inside C import block |
| 14 | 12 | // :3:17: error: C define valid only inside C import block |
test/cases/compile_errors/closure_get_in_param_ty_instantiate_incorrectly.zig-2| ... | ... | @@ -18,8 +18,6 @@ pub export fn entry() void { |
| 18 | 18 | } |
| 19 | 19 | |
| 20 | 20 | // error |
| 21 | // backend=stage2 | |
| 22 | // target=native | |
| 23 | 21 | // |
| 24 | 22 | // :17:25: error: expected type 'u32', found 'type' |
| 25 | 23 | // :3:21: note: parameter type declared here |
test/cases/compile_errors/coercion_to_error_union.zig-2| ... | ... | @@ -4,8 +4,6 @@ export fn b() void { |
| 4 | 4 | } |
| 5 | 5 | |
| 6 | 6 | // error |
| 7 | // backend=stage2 | |
| 8 | // target=native | |
| 9 | 7 | // |
| 10 | 8 | // 2:28: error: expected type 'anyerror!u8', found 'comptime_int' |
| 11 | 9 | // 2:28: note: type 'u8' cannot represent value '256' |
test/cases/compile_errors/coercion_to_optional.zig-2| ... | ... | @@ -4,8 +4,6 @@ export fn a() void { |
| 4 | 4 | } |
| 5 | 5 | |
| 6 | 6 | // error |
| 7 | // backend=stage2 | |
| 8 | // target=native | |
| 9 | 7 | // |
| 10 | 8 | // 2:20: error: expected type '?u8', found 'comptime_int' |
| 11 | 9 | // 2:20: note: type 'u8' cannot represent value '256' |
test/cases/compile_errors/compare_optional_to_non_optional_with_incomparable_type.zig-2| ... | ... | @@ -5,7 +5,5 @@ export fn entry() void { |
| 5 | 5 | } |
| 6 | 6 | |
| 7 | 7 | // error |
| 8 | // backend=stage2 | |
| 9 | // target=native | |
| 10 | 8 | // |
| 11 | 9 | // :4:12: error: operator == not allowed for type '?[3]i32' |
test/cases/compile_errors/comparing_a_non-optional_pointer_against_null.zig-2| ... | ... | @@ -4,7 +4,5 @@ export fn entry() void { |
| 4 | 4 | } |
| 5 | 5 | |
| 6 | 6 | // error |
| 7 | // backend=stage2 | |
| 8 | // target=native | |
| 9 | 7 | // |
| 10 | 8 | // :3:12: error: comparison of '*i32' with null |
test/cases/compile_errors/comparison_of_non-tagged_union_and_enum_literal.zig created+12| ... | ... | @@ -0,0 +1,12 @@ |
| 1 | export fn entry() void { | |
| 2 | const U = union { A: u32, B: u64 }; | |
| 3 | var u = U{ .A = 42 }; | |
| 4 | var ok = u == .A; | |
| 5 | _ = &u; | |
| 6 | _ = &ok; | |
| 7 | } | |
| 8 | ||
| 9 | // error | |
| 10 | // | |
| 11 | // :4:14: error: comparison of union and enum literal is only valid for tagged union types | |
| 12 | // :2:15: note: union 'tmp.entry.U' is not a tagged union |
test/cases/compile_errors/compileError_shows_traceback_of_references_that_caused_it.zig-2| ... | ... | @@ -10,7 +10,5 @@ export fn entry() i32 { |
| 10 | 10 | } |
| 11 | 11 | |
| 12 | 12 | // error |
| 13 | // backend=stage2 | |
| 14 | // target=native | |
| 15 | 13 | // |
| 16 | 14 | // :1:13: error: aoeu |
test/cases/compile_errors/compileLog_of_tagged_enum_doesnt_crash_the_compiler.zig-2| ... | ... | @@ -12,8 +12,6 @@ pub export fn entry() void { |
| 12 | 12 | } |
| 13 | 13 | |
| 14 | 14 | // error |
| 15 | // backend=stage2 | |
| 16 | // target=native | |
| 17 | 15 | // |
| 18 | 16 | // :6:5: error: found compile log statement |
| 19 | 17 | // :6:5: note: also here |
test/cases/compile_errors/compile_error_in_struct_init_expression.zig-2| ... | ... | @@ -10,7 +10,5 @@ export fn entry() void { |
| 10 | 10 | } |
| 11 | 11 | |
| 12 | 12 | // error |
| 13 | // backend=stage2 | |
| 14 | // target=native | |
| 15 | 13 | // |
| 16 | 14 | // :2:14: error: use of undeclared identifier 'crap' |
test/cases/compile_errors/compile_error_when_evaluating_return_type_of_inferred_error_set.zig-2| ... | ... | @@ -8,7 +8,5 @@ export fn entry() void { |
| 8 | 8 | } |
| 9 | 9 | |
| 10 | 10 | // error |
| 11 | // backend=stage2 | |
| 12 | // target=native | |
| 13 | 11 | // |
| 14 | 12 | // :2:11: error: use of undeclared identifier 'SymbolThatDoesNotExist' |
test/cases/compile_errors/compile_log.zig-2| ... | ... | @@ -13,8 +13,6 @@ export fn baz() void { |
| 13 | 13 | } |
| 14 | 14 | |
| 15 | 15 | // error |
| 16 | // backend=stage2 | |
| 17 | // target=native | |
| 18 | 16 | // |
| 19 | 17 | // :6:5: error: found compile log statement |
| 20 | 18 | // :6:5: note: also here |
test/cases/compile_errors/compile_log_statement_inside_function_which_must_be_comptime_evaluated.zig-2| ... | ... | @@ -8,8 +8,6 @@ export fn entry() void { |
| 8 | 8 | } |
| 9 | 9 | |
| 10 | 10 | // error |
| 11 | // backend=stage2 | |
| 12 | // target=native | |
| 13 | 11 | // |
| 14 | 12 | // :2:5: error: found compile log statement |
| 15 | 13 | // |
test/cases/compile_errors/compile_log_statement_warning_deduplication_in_generic_fn.zig-2| ... | ... | @@ -10,8 +10,6 @@ fn inner(comptime n: usize) void { |
| 10 | 10 | } |
| 11 | 11 | |
| 12 | 12 | // error |
| 13 | // backend=stage2 | |
| 14 | // target=native | |
| 15 | 13 | // |
| 16 | 14 | // :8:9: error: found compile log statement |
| 17 | 15 | // :8:9: note: also here |
test/cases/compile_errors/compile_time_null_ptr_cast.zig-2| ... | ... | @@ -5,7 +5,5 @@ comptime { |
| 5 | 5 | } |
| 6 | 6 | |
| 7 | 7 | // error |
| 8 | // backend=stage2 | |
| 9 | // target=native | |
| 10 | 8 | // |
| 11 | 9 | // :3:32: error: null pointer casted to type '*i32' |
test/cases/compile_errors/comptime_arg_to_generic_fn_callee_error.zig-2| ... | ... | @@ -14,8 +14,6 @@ pub export fn entry() void { |
| 14 | 14 | } |
| 15 | 15 | |
| 16 | 16 | // error |
| 17 | // backend=stage2 | |
| 18 | // target=native | |
| 19 | 17 | // |
| 20 | 18 | // :7:28: error: enum 'meta.FieldEnum(tmp.MyStruct)' has no member named 'c' |
| 21 | 19 | // :?:?: note: enum declared here |
test/cases/compile_errors/comptime_cast_enum_to_union_but_field_has_payload.zig-2| ... | ... | @@ -10,8 +10,6 @@ export fn entry() void { |
| 10 | 10 | } |
| 11 | 11 | |
| 12 | 12 | // error |
| 13 | // backend=stage2 | |
| 14 | // target=native | |
| 15 | 13 | // |
| 16 | 14 | // :8:26: error: coercion from enum 'tmp.Letter' to union 'tmp.Value' must initialize 'i32' field 'A' |
| 17 | 15 | // :3:5: note: field 'A' declared here |
test/cases/compile_errors/comptime_continue_inside_runtime_catch.zig-2| ... | ... | @@ -9,8 +9,6 @@ fn bad() !void { |
| 9 | 9 | } |
| 10 | 10 | |
| 11 | 11 | // error |
| 12 | // backend=stage2 | |
| 13 | // target=native | |
| 14 | 12 | // |
| 15 | 13 | // :4:21: error: comptime control flow inside runtime block |
| 16 | 14 | // :4:15: note: runtime control flow here |
test/cases/compile_errors/comptime_continue_inside_runtime_if_bool.zig-2| ... | ... | @@ -9,8 +9,6 @@ export fn entry() void { |
| 9 | 9 | } |
| 10 | 10 | |
| 11 | 11 | // error |
| 12 | // backend=stage2 | |
| 13 | // target=native | |
| 14 | 12 | // |
| 15 | 13 | // :6:22: error: comptime control flow inside runtime block |
| 16 | 14 | // :6:15: note: runtime control flow here |
test/cases/compile_errors/comptime_continue_inside_runtime_if_error.zig-2| ... | ... | @@ -9,8 +9,6 @@ export fn entry() void { |
| 9 | 9 | } |
| 10 | 10 | |
| 11 | 11 | // error |
| 12 | // backend=stage2 | |
| 13 | // target=native | |
| 14 | 12 | // |
| 15 | 13 | // :6:20: error: comptime control flow inside runtime block |
| 16 | 14 | // :6:13: note: runtime control flow here |
test/cases/compile_errors/comptime_continue_inside_runtime_if_optional.zig-2| ... | ... | @@ -9,8 +9,6 @@ export fn entry() void { |
| 9 | 9 | } |
| 10 | 10 | |
| 11 | 11 | // error |
| 12 | // backend=stage2 | |
| 13 | // target=native | |
| 14 | 12 | // |
| 15 | 13 | // :6:20: error: comptime control flow inside runtime block |
| 16 | 14 | // :6:13: note: runtime control flow here |
test/cases/compile_errors/comptime_continue_inside_runtime_orelse.zig-2| ... | ... | @@ -9,8 +9,6 @@ fn bad() ?void { |
| 9 | 9 | } |
| 10 | 10 | |
| 11 | 11 | // error |
| 12 | // backend=stage2 | |
| 13 | // target=native | |
| 14 | 12 | // |
| 15 | 13 | // :4:22: error: comptime control flow inside runtime block |
| 16 | 14 | // :4:15: note: runtime control flow here |
test/cases/compile_errors/comptime_continue_inside_runtime_switch.zig-2| ... | ... | @@ -12,8 +12,6 @@ export fn entry() void { |
| 12 | 12 | } |
| 13 | 13 | |
| 14 | 14 | // error |
| 15 | // backend=stage2 | |
| 16 | // target=native | |
| 17 | 15 | // |
| 18 | 16 | // :7:19: error: comptime control flow inside runtime block |
| 19 | 17 | // :6:17: note: runtime control flow here |
test/cases/compile_errors/comptime_continue_inside_runtime_while_bool.zig-2| ... | ... | @@ -9,8 +9,6 @@ export fn entry() void { |
| 9 | 9 | } |
| 10 | 10 | |
| 11 | 11 | // error |
| 12 | // backend=stage2 | |
| 13 | // target=native | |
| 14 | 12 | // |
| 15 | 13 | // :6:25: error: comptime control flow inside runtime block |
| 16 | 14 | // :6:18: note: runtime control flow here |
test/cases/compile_errors/comptime_continue_inside_runtime_while_error.zig-2| ... | ... | @@ -11,8 +11,6 @@ export fn entry() void { |
| 11 | 11 | } |
| 12 | 12 | |
| 13 | 13 | // error |
| 14 | // backend=stage2 | |
| 15 | // target=native | |
| 16 | 14 | // |
| 17 | 15 | // :7:13: error: comptime control flow inside runtime block |
| 18 | 16 | // :6:16: note: runtime control flow here |
test/cases/compile_errors/comptime_continue_inside_runtime_while_optional.zig-2| ... | ... | @@ -9,8 +9,6 @@ export fn entry() void { |
| 9 | 9 | } |
| 10 | 10 | |
| 11 | 11 | // error |
| 12 | // backend=stage2 | |
| 13 | // target=native | |
| 14 | 12 | // |
| 15 | 13 | // :6:23: error: comptime control flow inside runtime block |
| 16 | 14 | // :6:16: note: runtime control flow here |
test/cases/compile_errors/comptime_continue_to_outer_inline_loop.zig-2| ... | ... | @@ -15,8 +15,6 @@ pub export fn entry() void { |
| 15 | 15 | } |
| 16 | 16 | |
| 17 | 17 | // error |
| 18 | // backend=stage2 | |
| 19 | // target=native | |
| 20 | 18 | // |
| 21 | 19 | // :10:30: error: comptime control flow inside runtime block |
| 22 | 20 | // :7:13: note: runtime control flow here |
test/cases/compile_errors/comptime_if_inside_runtime_for.zig-2| ... | ... | @@ -8,8 +8,6 @@ export fn entry() void { |
| 8 | 8 | } |
| 9 | 9 | |
| 10 | 10 | // error |
| 11 | // backend=stage2 | |
| 12 | // target=native | |
| 13 | 11 | // |
| 14 | 12 | // :5:21: error: value with comptime-only type 'comptime_int' depends on runtime control flow |
| 15 | 13 | // :4:10: note: runtime control flow here |
test/cases/compile_errors/comptime_implicit_cast_f64_to_f32.zig-2| ... | ... | @@ -5,7 +5,5 @@ export fn entry() void { |
| 5 | 5 | } |
| 6 | 6 | |
| 7 | 7 | // error |
| 8 | // backend=stage2 | |
| 9 | // target=native | |
| 10 | 8 | // |
| 11 | 9 | // :3:20: error: type 'f32' cannot represent float value '16777217' |
test/cases/compile_errors/comptime_param_coersion.zig-2| ... | ... | @@ -11,8 +11,6 @@ fn foo(comptime _: i32, comptime _: i32) void {} |
| 11 | 11 | fn bar(comptime _: i32, _: i32) void {} |
| 12 | 12 | |
| 13 | 13 | // error |
| 14 | // backend=stage2 | |
| 15 | // target=native | |
| 16 | 14 | // |
| 17 | 15 | // :3:9: error: expected type 'fn (comptime i32, comptime i32) void', found 'fn (comptime i32, i32) void' |
| 18 | 16 | // :3:9: note: non-comptime parameter 1 cannot cast into a comptime parameter |
test/cases/compile_errors/comptime_slice-sentinel_does_not_match_memory_at_target_index_terminated.zig-2| ... | ... | @@ -55,8 +55,6 @@ export fn foo_slice() void { |
| 55 | 55 | } |
| 56 | 56 | |
| 57 | 57 | // error |
| 58 | // backend=stage2 | |
| 59 | // target=native | |
| 60 | 58 | // |
| 61 | 59 | // :4:29: error: value in memory does not match slice sentinel |
| 62 | 60 | // :4:29: note: expected '0', found '100' |
test/cases/compile_errors/comptime_slice-sentinel_does_not_match_memory_at_target_index_unterminated.zig-2| ... | ... | @@ -55,8 +55,6 @@ export fn foo_slice() void { |
| 55 | 55 | } |
| 56 | 56 | |
| 57 | 57 | // error |
| 58 | // backend=stage2 | |
| 59 | // target=native | |
| 60 | 58 | // |
| 61 | 59 | // :4:29: error: value in memory does not match slice sentinel |
| 62 | 60 | // :4:29: note: expected '0', found '100' |
test/cases/compile_errors/comptime_slice-sentinel_does_not_match_target-sentinel.zig-2| ... | ... | @@ -70,8 +70,6 @@ export fn typeName_slice() void { |
| 70 | 70 | } |
| 71 | 71 | |
| 72 | 72 | // error |
| 73 | // backend=stage2 | |
| 74 | // target=native | |
| 75 | 73 | // |
| 76 | 74 | // :4:29: error: value in memory does not match slice sentinel |
| 77 | 75 | // :4:29: note: expected '255', found '0' |
test/cases/compile_errors/comptime_slice-sentinel_is_out_of_bounds_terminated.zig-2| ... | ... | @@ -55,8 +55,6 @@ export fn foo_slice() void { |
| 55 | 55 | } |
| 56 | 56 | |
| 57 | 57 | // error |
| 58 | // backend=stage2 | |
| 59 | // target=native | |
| 60 | 58 | // |
| 61 | 59 | // :4:33: error: slice end index 15 exceeds bounds of containing decl of type '[14:0]u8' |
| 62 | 60 | // :12:33: error: slice end index 15 exceeds bounds of containing decl of type '[14:0]u8' |
test/cases/compile_errors/comptime_slice-sentinel_is_out_of_bounds_unterminated.zig-2| ... | ... | @@ -55,8 +55,6 @@ export fn foo_slice() void { |
| 55 | 55 | } |
| 56 | 56 | |
| 57 | 57 | // error |
| 58 | // backend=stage2 | |
| 59 | // target=native | |
| 60 | 58 | // |
| 61 | 59 | // :4:33: error: slice end index 14 exceeds bounds of containing decl of type '[14]u8' |
| 62 | 60 | // :12:33: error: slice end index 14 exceeds bounds of containing decl of type '[14]u8' |
test/cases/compile_errors/comptime_slice_of_an_undefined_slice.zig-2| ... | ... | @@ -5,7 +5,5 @@ comptime { |
| 5 | 5 | } |
| 6 | 6 | |
| 7 | 7 | // error |
| 8 | // backend=stage2 | |
| 9 | // target=native | |
| 10 | 8 | // |
| 11 | 9 | // :3:14: error: slice of undefined |
test/cases/compile_errors/comptime_slice_of_undefined_pointer_non-zero_len.zig-2| ... | ... | @@ -4,7 +4,5 @@ export fn entry() void { |
| 4 | 4 | } |
| 5 | 5 | |
| 6 | 6 | // error |
| 7 | // backend=stage2 | |
| 8 | // target=native | |
| 9 | 7 | // |
| 10 | 8 | // :2:41: error: non-zero length slice of undefined pointer |
test/cases/compile_errors/comptime_store_in_comptime_switch_in_runtime_if.zig-2| ... | ... | @@ -18,8 +18,6 @@ pub export fn entry() void { |
| 18 | 18 | } |
| 19 | 19 | |
| 20 | 20 | // error |
| 21 | // backend=stage2 | |
| 22 | // target=native | |
| 23 | 21 | // |
| 24 | 22 | // :13:25: error: store to comptime variable depends on runtime condition |
| 25 | 23 | // :11:16: note: runtime condition here |
test/cases/compile_errors/comptime_struct_field_no_init_value.zig-2| ... | ... | @@ -7,7 +7,5 @@ export fn entry() void { |
| 7 | 7 | } |
| 8 | 8 | |
| 9 | 9 | // error |
| 10 | // backend=stage2 | |
| 11 | // target=native | |
| 12 | 10 | // |
| 13 | 11 | // :2:5: error: comptime field without default initialization value |
test/cases/compile_errors/comptime_unreachable.zig-2| ... | ... | @@ -3,7 +3,5 @@ pub export fn entry() void { |
| 3 | 3 | } |
| 4 | 4 | |
| 5 | 5 | // error |
| 6 | // target=native | |
| 7 | // backend=stage2 | |
| 8 | 6 | // |
| 9 | 7 | // :2:14: error: reached unreachable code |
test/cases/compile_errors/const_is_a_statement_not_an_expression.zig-2| ... | ... | @@ -3,7 +3,5 @@ export fn f() void { |
| 3 | 3 | } |
| 4 | 4 | |
| 5 | 5 | // error |
| 6 | // backend=stage2 | |
| 7 | // target=native | |
| 8 | 6 | // |
| 9 | 7 | // :2:6: error: expected expression, found 'const' |
test/cases/compile_errors/container_init_with_non-type.zig-2| ... | ... | @@ -6,7 +6,5 @@ export fn entry() usize { |
| 6 | 6 | } |
| 7 | 7 | |
| 8 | 8 | // error |
| 9 | // backend=stage2 | |
| 10 | // target=native | |
| 11 | 9 | // |
| 12 | 10 | // :2:11: error: expected type 'type', found 'i32' |
test/cases/compile_errors/control_flow_uses_comptime_var_at_runtime.zig-2| ... | ... | @@ -29,8 +29,6 @@ export fn qux() void { |
| 29 | 29 | } |
| 30 | 30 | |
| 31 | 31 | // error |
| 32 | // backend=stage2 | |
| 33 | // target=native | |
| 34 | 32 | // |
| 35 | 33 | // :3:24: error: cannot store to comptime variable in non-inline loop |
| 36 | 34 | // :3:5: note: non-inline loop here |
test/cases/compile_errors/decl_shadows_local.zig-2| ... | ... | @@ -14,8 +14,6 @@ fn bar(a: usize) void { |
| 14 | 14 | } |
| 15 | 15 | |
| 16 | 16 | // error |
| 17 | // backend=stage2 | |
| 18 | // target=native | |
| 19 | 17 | // |
| 20 | 18 | // :3:15: error: declaration 'a' shadows function parameter from outer scope |
| 21 | 19 | // :1:8: note: previous declaration here |
test/cases/compile_errors/declaration_between_fields.zig-2| ... | ... | @@ -16,8 +16,6 @@ comptime { |
| 16 | 16 | } |
| 17 | 17 | |
| 18 | 18 | // error |
| 19 | // backend=stage2 | |
| 20 | // target=native | |
| 21 | 19 | // |
| 22 | 20 | // :9:5: error: declarations are not allowed between container fields |
| 23 | 21 | // :5:5: note: field before declarations here |
test/cases/compile_errors/declaration_with_same_name_as_primitive_must_use_special_syntax.zig-2| ... | ... | @@ -5,8 +5,6 @@ export fn entry() void { |
| 5 | 5 | } |
| 6 | 6 | |
| 7 | 7 | // error |
| 8 | // backend=stage2 | |
| 9 | // target=native | |
| 10 | 8 | // |
| 11 | 9 | // :1:7: error: name shadows primitive 'u8' |
| 12 | 10 | // :1:7: note: consider using @"u8" to disambiguate |
test/cases/compile_errors/deduplicate_undeclared_identifier.zig-2| ... | ... | @@ -6,8 +6,6 @@ export fn b() void { |
| 6 | 6 | } |
| 7 | 7 | |
| 8 | 8 | // error |
| 9 | // backend=stage2 | |
| 10 | // target=native | |
| 11 | 9 | // |
| 12 | 10 | // :2:5: error: use of undeclared identifier 'x' |
| 13 | 11 | // :5:5: error: use of undeclared identifier 'x' |
test/cases/compile_errors/deref_on_undefined_value.zig-2| ... | ... | @@ -4,7 +4,5 @@ comptime { |
| 4 | 4 | } |
| 5 | 5 | |
| 6 | 6 | // error |
| 7 | // backend=stage2 | |
| 8 | // target=native | |
| 9 | 7 | // |
| 10 | 8 | // :3:10: error: cannot dereference undefined value |
test/cases/compile_errors/deref_slice_and_get_len_field.zig-2| ... | ... | @@ -5,7 +5,5 @@ export fn entry() void { |
| 5 | 5 | } |
| 6 | 6 | |
| 7 | 7 | // error |
| 8 | // backend=stage2 | |
| 9 | // target=native | |
| 10 | 8 | // |
| 11 | 9 | // :3:10: error: index syntax required for slice type '[]u8' |
test/cases/compile_errors/dereference_an_array.zig-2| ... | ... | @@ -11,7 +11,5 @@ export fn entry() usize { |
| 11 | 11 | } |
| 12 | 12 | |
| 13 | 13 | // error |
| 14 | // backend=stage2 | |
| 15 | // target=native | |
| 16 | 14 | // |
| 17 | 15 | // :5:10: error: cannot dereference non-pointer type '[10]u8' |
test/cases/compile_errors/dereference_slice.zig-2| ... | ... | @@ -6,7 +6,5 @@ comptime { |
| 6 | 6 | } |
| 7 | 7 | |
| 8 | 8 | // error |
| 9 | // backend=stage2 | |
| 10 | // target=native | |
| 11 | 9 | // |
| 12 | 10 | // :2:13: error: index syntax required for slice type '[]i32' |
test/cases/compile_errors/dereference_unknown_length_pointer.zig-2| ... | ... | @@ -3,7 +3,5 @@ export fn entry(x: [*]i32) i32 { |
| 3 | 3 | } |
| 4 | 4 | |
| 5 | 5 | // error |
| 6 | // backend=stage2 | |
| 7 | // target=native | |
| 8 | 6 | // |
| 9 | 7 | // :2:13: error: index syntax required for unknown-length pointer type '[*]i32' |
test/cases/compile_errors/dereferencing_invalid_payload_ptr_at_comptime.zig-2| ... | ... | @@ -25,8 +25,6 @@ comptime { |
| 25 | 25 | } |
| 26 | 26 | |
| 27 | 27 | // error |
| 28 | // backend=stage2 | |
| 29 | // target=native | |
| 30 | 28 | // |
| 31 | 29 | // :16:20: error: attempt to use null value |
| 32 | 30 | // :24:20: error: attempt to unwrap error: Foo |
test/cases/compile_errors/destructure_error_union.zig-2| ... | ... | @@ -7,8 +7,6 @@ pub export fn entry() void { |
| 7 | 7 | } |
| 8 | 8 | |
| 9 | 9 | // error |
| 10 | // backend=stage2 | |
| 11 | // target=native | |
| 12 | 10 | // |
| 13 | 11 | // :4:28: error: type 'anyerror!struct { u8, u8 }' cannot be destructured |
| 14 | 12 | // :4:26: note: result destructured here |
test/cases/compile_errors/direct_struct_loop.zig-2| ... | ... | @@ -6,7 +6,5 @@ export fn entry() usize { |
| 6 | 6 | } |
| 7 | 7 | |
| 8 | 8 | // error |
| 9 | // backend=stage2 | |
| 10 | // target=native | |
| 11 | 9 | // |
| 12 | 10 | // :1:11: error: struct 'tmp.A' depends on itself |
test/cases/compile_errors/directly_embedding_opaque_type_in_struct_and_union.zig-2| ... | ... | @@ -25,8 +25,6 @@ export fn d() void { |
| 25 | 25 | } |
| 26 | 26 | |
| 27 | 27 | // error |
| 28 | // backend=stage2 | |
| 29 | // target=native | |
| 30 | 28 | // |
| 31 | 29 | // :3:8: error: opaque types have unknown size and therefore cannot be directly embedded in structs |
| 32 | 30 | // :1:11: note: opaque declared here |
test/cases/compile_errors/disallow_coercion_from_non-null-terminated_pointer_to_null-terminated_pointer.zig-2| ... | ... | @@ -6,8 +6,6 @@ pub export fn entry() void { |
| 6 | 6 | } |
| 7 | 7 | |
| 8 | 8 | // error |
| 9 | // backend=stage2 | |
| 10 | // target=native | |
| 11 | 9 | // |
| 12 | 10 | // :5:14: error: expected type '[*:0]const u8', found '[*]const u8' |
| 13 | 11 | // :5:14: note: destination pointer requires '0' sentinel |
test/cases/compile_errors/discarded_array_bad_elem_type.zig-2| ... | ... | @@ -6,7 +6,5 @@ export fn foo() void { |
| 6 | 6 | } |
| 7 | 7 | |
| 8 | 8 | // error |
| 9 | // backend=stage2 | |
| 10 | // target=native | |
| 11 | 9 | // |
| 12 | 10 | // :3:9: error: expected type 'u16', found '*const [5:0]u8' |
test/cases/compile_errors/discarding_error_value.zig-2| ... | ... | @@ -10,8 +10,6 @@ export fn entry2() void { |
| 10 | 10 | } |
| 11 | 11 | |
| 12 | 12 | // error |
| 13 | // backend=stage2 | |
| 14 | // target=native | |
| 15 | 13 | // |
| 16 | 14 | // :2:12: error: error union is discarded |
| 17 | 15 | // :2:12: note: consider using 'try', 'catch', or 'if' |
test/cases/compile_errors/div_overflow.zig-2| ... | ... | @@ -5,7 +5,5 @@ comptime { |
| 5 | 5 | } |
| 6 | 6 | |
| 7 | 7 | // error |
| 8 | // backend=stage2 | |
| 9 | // target=native | |
| 10 | 8 | // |
| 11 | 9 | // :4:11: error: overflow of integer type 'i8' with value '128' |
test/cases/compile_errors/double_pointer_to_anyopaque_pointer.zig-2| ... | ... | @@ -23,8 +23,6 @@ export fn entry4() void { |
| 23 | 23 | } |
| 24 | 24 | |
| 25 | 25 | // error |
| 26 | // backend=stage2 | |
| 27 | // target=native | |
| 28 | 26 | // |
| 29 | 27 | // :4:35: error: expected type '*const anyopaque', found '*const *const usize' |
| 30 | 28 | // :4:35: note: cannot implicitly cast double pointer '*const *const usize' to anyopaque pointer '*const anyopaque' |
test/cases/compile_errors/duplicate-unused_labels.zig-1| ... | ... | @@ -29,7 +29,6 @@ comptime { |
| 29 | 29 | } |
| 30 | 30 | |
| 31 | 31 | // error |
| 32 | // target=native | |
| 33 | 32 | // |
| 34 | 33 | // :3:9: error: redefinition of label 'blk' |
| 35 | 34 | // :2:5: note: previous definition here |
test/cases/compile_errors/duplicate_boolean_switch_value.zig-2| ... | ... | @@ -16,8 +16,6 @@ comptime { |
| 16 | 16 | } |
| 17 | 17 | |
| 18 | 18 | // error |
| 19 | // backend=stage2 | |
| 20 | // target=native | |
| 21 | 19 | // |
| 22 | 20 | // :5:9: error: duplicate switch value |
| 23 | 21 | // :13:9: error: duplicate switch value |
test/cases/compile_errors/duplicate_enum_field.zig-2| ... | ... | @@ -9,8 +9,6 @@ export fn entry() void { |
| 9 | 9 | } |
| 10 | 10 | |
| 11 | 11 | // error |
| 12 | // backend=stage2 | |
| 13 | // target=native | |
| 14 | 12 | // |
| 15 | 13 | // :2:5: error: duplicate enum member name 'Bar' |
| 16 | 14 | // :3:5: note: duplicate name here |
test/cases/compile_errors/duplicate_error_in_switch.zig-2| ... | ... | @@ -15,8 +15,6 @@ fn foo(x: i32) !void { |
| 15 | 15 | } |
| 16 | 16 | |
| 17 | 17 | // error |
| 18 | // backend=stage2 | |
| 19 | // target=native | |
| 20 | 18 | // |
| 21 | 19 | // :5:9: error: duplicate switch value |
| 22 | 20 | // :3:9: note: previous value here |
test/cases/compile_errors/duplicate_error_value_in_error_set.zig-2| ... | ... | @@ -8,8 +8,6 @@ export fn entry() void { |
| 8 | 8 | } |
| 9 | 9 | |
| 10 | 10 | // error |
| 11 | // backend=stage2 | |
| 12 | // target=native | |
| 13 | 11 | // |
| 14 | 12 | // :3:5: error: duplicate error set field 'Bar' |
| 15 | 13 | // :2:5: note: previous declaration here |
test/cases/compile_errors/duplicate_field_in_anonymous_struct_literal.zig-2| ... | ... | @@ -11,8 +11,6 @@ export fn entry() void { |
| 11 | 11 | } |
| 12 | 12 | |
| 13 | 13 | // error |
| 14 | // backend=stage2 | |
| 15 | // target=native | |
| 16 | 14 | // |
| 17 | 15 | // :4:14: error: duplicate struct field name |
| 18 | 16 | // :7:14: note: duplicate name here |
test/cases/compile_errors/duplicate_field_in_discarded_anon_init.zig-2| ... | ... | @@ -3,8 +3,6 @@ pub export fn entry() void { |
| 3 | 3 | } |
| 4 | 4 | |
| 5 | 5 | // error |
| 6 | // backend=stage2 | |
| 7 | // target=native | |
| 8 | 6 | // |
| 9 | 7 | // :2:13: error: duplicate struct field name |
| 10 | 8 | // :2:21: note: duplicate name here |
test/cases/compile_errors/duplicate_field_in_struct_value_expression.zig-2| ... | ... | @@ -14,8 +14,6 @@ export fn f() void { |
| 14 | 14 | } |
| 15 | 15 | |
| 16 | 16 | // error |
| 17 | // backend=stage2 | |
| 18 | // target=native | |
| 19 | 17 | // |
| 20 | 18 | // :8:10: error: duplicate struct field name |
| 21 | 19 | // :11:10: note: duplicate name here |
test/cases/compile_errors/duplicate_struct_field.zig-2| ... | ... | @@ -21,8 +21,6 @@ export fn b() void { |
| 21 | 21 | } |
| 22 | 22 | |
| 23 | 23 | // error |
| 24 | // backend=stage2 | |
| 25 | // target=native | |
| 26 | 24 | // |
| 27 | 25 | // :2:5: error: duplicate struct member name 'Bar' |
| 28 | 26 | // :3:5: note: duplicate name here |
test/cases/compile_errors/embedFile_with_bogus_file.zig-2| ... | ... | @@ -5,7 +5,5 @@ export fn entry() usize { |
| 5 | 5 | } |
| 6 | 6 | |
| 7 | 7 | // error |
| 8 | // backend=stage2 | |
| 9 | // target=native | |
| 10 | 8 | // |
| 11 | 9 | // :1:29: error: unable to open 'bogus.txt': FileNotFound |
test/cases/compile_errors/embed_outside_package.zig-1| ... | ... | @@ -3,6 +3,5 @@ export fn a() usize { |
| 3 | 3 | } |
| 4 | 4 | |
| 5 | 5 | // error |
| 6 | // target=native | |
| 7 | 6 | // |
| 8 | 7 | //:2:23: error: embed of file outside package path: '/root/foo' |
test/cases/compile_errors/empty_char_lit.zig-2| ... | ... | @@ -3,7 +3,5 @@ export fn entry() u8 { |
| 3 | 3 | } |
| 4 | 4 | |
| 5 | 5 | // error |
| 6 | // backend=stage2 | |
| 7 | // target=native | |
| 8 | 6 | // |
| 9 | 7 | // :2:12: error: empty character literal |
test/cases/compile_errors/empty_for_loop_body.zig-2| ... | ... | @@ -3,7 +3,5 @@ export fn a() void { |
| 3 | 3 | } |
| 4 | 4 | |
| 5 | 5 | // error |
| 6 | // backend=stage2 | |
| 7 | // target=native | |
| 8 | 6 | // |
| 9 | 7 | // :2:23: error: expected block or assignment, found ';' |
test/cases/compile_errors/empty_if_body.zig-2| ... | ... | @@ -3,7 +3,5 @@ export fn a() void { |
| 3 | 3 | } |
| 4 | 4 | |
| 5 | 5 | // error |
| 6 | // backend=stage2 | |
| 7 | // target=native | |
| 8 | 6 | // |
| 9 | 7 | // :2:13: error: expected block or assignment, found ';' |
test/cases/compile_errors/empty_switch_on_an_integer.zig-2| ... | ... | @@ -4,7 +4,5 @@ export fn entry() void { |
| 4 | 4 | } |
| 5 | 5 | |
| 6 | 6 | // error |
| 7 | // backend=stage2 | |
| 8 | // target=native | |
| 9 | 7 | // |
| 10 | 8 | // :3:5: error: switch must handle all possibilities |
test/cases/compile_errors/empty_while_loop_body.zig-2| ... | ... | @@ -3,7 +3,5 @@ export fn a() void { |
| 3 | 3 | } |
| 4 | 4 | |
| 5 | 5 | // error |
| 6 | // backend=stage2 | |
| 7 | // target=native | |
| 8 | 6 | // |
| 9 | 7 | // :2:16: error: expected block or assignment, found ';' |
test/cases/compile_errors/enumFromInt_on_non-exhaustive_enums_checks_int_in_range.zig-2| ... | ... | @@ -4,8 +4,6 @@ pub export fn entry() void { |
| 4 | 4 | } |
| 5 | 5 | |
| 6 | 6 | // error |
| 7 | // target=native | |
| 8 | // backend=stage2 | |
| 9 | 7 | // |
| 10 | 8 | // :3:24: error: int value '100' out of range of non-exhaustive enum 'tmp.entry.E' |
| 11 | 9 | // :2:15: note: enum declared here |
test/cases/compile_errors/enum_backed_by_comptime_int_must_be_casted_from_comptime_value.zig-2| ... | ... | @@ -7,8 +7,6 @@ export fn entry() void { |
| 7 | 7 | } |
| 8 | 8 | |
| 9 | 9 | // error |
| 10 | // backend=stage2 | |
| 11 | // target=native | |
| 12 | 10 | // |
| 13 | 11 | // :6:31: error: unable to resolve comptime value |
| 14 | 12 | // :6:31: note: value casted to enum with 'comptime_int' tag type must be comptime-known |
test/cases/compile_errors/enum_backed_by_comptime_int_must_be_comptime.zig-2| ... | ... | @@ -5,7 +5,5 @@ pub export fn entry() void { |
| 5 | 5 | } |
| 6 | 6 | |
| 7 | 7 | // error |
| 8 | // backend=stage2 | |
| 9 | // target=native | |
| 10 | 8 | // |
| 11 | 9 | // :3:12: error: variable of type 'tmp.entry.E' must be const or comptime |
test/cases/compile_errors/enum_field_value_references_enum.zig-2| ... | ... | @@ -9,7 +9,5 @@ export fn entry() void { |
| 9 | 9 | const D = 1; |
| 10 | 10 | |
| 11 | 11 | // error |
| 12 | // backend=stage2 | |
| 13 | // target=native | |
| 14 | 12 | // |
| 15 | 13 | // :1:5: error: dependency loop detected |
test/cases/compile_errors/enum_in_field_count_range_but_not_matching_tag.zig-2| ... | ... | @@ -8,8 +8,6 @@ export fn entry() void { |
| 8 | 8 | } |
| 9 | 9 | |
| 10 | 10 | // error |
| 11 | // backend=stage2 | |
| 12 | // target=native | |
| 13 | 11 | // |
| 14 | 12 | // :6:20: error: enum 'tmp.Foo' has no tag with value '0' |
| 15 | 13 | // :1:13: note: enum declared here |
test/cases/compile_errors/enum_value_already_taken.zig-2| ... | ... | @@ -11,8 +11,6 @@ export fn entry() void { |
| 11 | 11 | } |
| 12 | 12 | |
| 13 | 13 | // error |
| 14 | // backend=stage2 | |
| 15 | // target=native | |
| 16 | 14 | // |
| 17 | 15 | // :6:9: error: enum tag value 60 already taken |
| 18 | 16 | // :4:9: note: other occurrence here |
test/cases/compile_errors/enum_with_declarations_unavailable_for_reify_type.zig-2| ... | ... | @@ -6,7 +6,5 @@ export fn entry() void { |
| 6 | 6 | } |
| 7 | 7 | |
| 8 | 8 | // error |
| 9 | // backend=stage2 | |
| 10 | // target=native | |
| 11 | 9 | // |
| 12 | 10 | // :2:9: error: reified enums must have no decls |
test/cases/compile_errors/error_in_call_builtin_args.zig-2| ... | ... | @@ -8,8 +8,6 @@ pub export fn entry1() void { |
| 8 | 8 | } |
| 9 | 9 | |
| 10 | 10 | // error |
| 11 | // backend=stage2 | |
| 12 | // target=native | |
| 13 | 11 | // |
| 14 | 12 | // :3:30: error: fractional component prevents float value '12.34' from coercion to type 'u32' |
| 15 | 13 | // :7:23: error: fractional component prevents float value '12.34' from coercion to type 'u32' |
test/cases/compile_errors/error_in_typeof_param.zig-2| ... | ... | @@ -7,8 +7,6 @@ pub export fn entry() void { |
| 7 | 7 | } |
| 8 | 8 | |
| 9 | 9 | // error |
| 10 | // backend=stage2 | |
| 11 | // target=native | |
| 12 | 10 | // |
| 13 | 11 | // :6:31: error: unable to resolve comptime value |
| 14 | 12 | // :6:31: note: value casted to 'comptime_int' must be comptime-known |
test/cases/compile_errors/error_not_handled_in_switch.zig-2| ... | ... | @@ -13,8 +13,6 @@ fn foo(x: i32) !void { |
| 13 | 13 | } |
| 14 | 14 | |
| 15 | 15 | // error |
| 16 | // backend=stage2 | |
| 17 | // target=native | |
| 18 | 16 | // |
| 19 | 17 | // :2:26: error: switch must handle all possibilities |
| 20 | 18 | // :2:26: note: unhandled error value: 'error.Bar' |
test/cases/compile_errors/error_note_for_function_parameter_incompatibility.zig-2| ... | ... | @@ -9,8 +9,6 @@ export fn entry() void { |
| 9 | 9 | } |
| 10 | 10 | |
| 11 | 11 | // error |
| 12 | // backend=stage2 | |
| 13 | // target=native | |
| 14 | 12 | // |
| 15 | 13 | // :8:18: error: expected type '*const fn (i32) void', found '*const fn (bool) void' |
| 16 | 14 | // :8:18: note: pointer type child 'fn (bool) void' cannot cast into pointer type child 'fn (i32) void' |
test/cases/compile_errors/error_set_cannot_capture_by_reference.zig-2| ... | ... | @@ -9,7 +9,5 @@ export fn entry() void { |
| 9 | 9 | } |
| 10 | 10 | |
| 11 | 11 | // error |
| 12 | // backend=stage2 | |
| 13 | // target=native | |
| 14 | 12 | // |
| 15 | 13 | // :5:23: error: error set cannot be captured by reference |
test/cases/compile_errors/error_set_membership.zig-1| ... | ... | @@ -24,7 +24,6 @@ pub fn main() Error!void { |
| 24 | 24 | } |
| 25 | 25 | |
| 26 | 26 | // error |
| 27 | // backend=stage2 | |
| 28 | 27 | // target=x86_64-linux |
| 29 | 28 | // |
| 30 | 29 | // :23:29: error: expected type 'error{InvalidCharacter}', found '@typeInfo(@typeInfo(@TypeOf(tmp.fooey)).@"fn".return_type.?).error_union.error_set' |
test/cases/compile_errors/error_union_operator_with_non_error_set_LHS.zig-2| ... | ... | @@ -5,7 +5,5 @@ comptime { |
| 5 | 5 | } |
| 6 | 6 | |
| 7 | 7 | // error |
| 8 | // backend=stage2 | |
| 9 | // target=native | |
| 10 | 8 | // |
| 11 | 9 | // :2:15: error: expected error set type, found 'i32' |
test/cases/compile_errors/error_when_evaluating_return_type.zig-2| ... | ... | @@ -11,7 +11,5 @@ export fn entry() void { |
| 11 | 11 | } |
| 12 | 12 | |
| 13 | 13 | // error |
| 14 | // backend=stage2 | |
| 15 | // target=native | |
| 16 | 14 | // |
| 17 | 15 | // :2:19: error: expected type 'i32', found 'type' |
test/cases/compile_errors/errors_in_for_loop_bodies_are_propagated.zig-2| ... | ... | @@ -4,7 +4,5 @@ pub export fn entry() void { |
| 4 | 4 | } |
| 5 | 5 | |
| 6 | 6 | // error |
| 7 | // backend=stage2 | |
| 8 | // target=native | |
| 9 | 7 | // |
| 10 | 8 | // :3:26: error: expected 1 argument, found 2 |
test/cases/compile_errors/exact division failure.zig	-2| ... | ... | @@ -4,7 +4,5 @@ comptime { |
| 4 | 4 | } |
| 5 | 5 | |
| 6 | 6 | // error |
| 7 | // backend=stage2 | |
| 8 | // target=native | |
| 9 | 7 | // |
| 10 | 8 | // :2:15: error: exact division produced remainder |
test/cases/compile_errors/exceeded_maximum_bit_width_of_integer.zig-2| ... | ... | @@ -8,8 +8,6 @@ export fn entry2() void { |
| 8 | 8 | } |
| 9 | 9 | |
| 10 | 10 | // error |
| 11 | // backend=stage2 | |
| 12 | // target=native | |
| 13 | 11 | // |
| 14 | 12 | // :2:15: error: primitive integer type 'u65536' exceeds maximum bit width of 65535 |
| 15 | 13 | // :6:12: error: primitive integer type 'i65536' exceeds maximum bit width of 65535 |
test/cases/compile_errors/expected_optional_type_got_container.zig-2| ... | ... | @@ -9,8 +9,6 @@ fn bar() X { |
| 9 | 9 | } |
| 10 | 10 | |
| 11 | 11 | // error |
| 12 | // backend=stage2 | |
| 13 | // target=native | |
| 14 | 12 | // |
| 15 | 13 | // :2:15: error: expected optional type, found 'tmp.X' |
| 16 | 14 | // :6:11: note: enum declared here |
test/cases/compile_errors/explicit_cast_float_literal_to_integer_when_there_is_a_fraction_component.zig-2| ... | ... | @@ -3,7 +3,5 @@ export fn entry() i32 { |
| 3 | 3 | } |
| 4 | 4 | |
| 5 | 5 | // error |
| 6 | // backend=stage2 | |
| 7 | // target=native | |
| 8 | 6 | // |
| 9 | 7 | // :2:21: error: fractional component prevents float value '12.34' from coercion to type 'i32' |
test/cases/compile_errors/explicit_error_set_cast_known_at_comptime_violates_error_sets.zig-2| ... | ... | @@ -7,7 +7,5 @@ comptime { |
| 7 | 7 | } |
| 8 | 8 | |
| 9 | 9 | // error |
| 10 | // backend=stage2 | |
| 11 | // target=native | |
| 12 | 10 | // |
| 13 | 11 | // :5:21: error: 'error.B' not a member of error set 'error{A,C}' |
test/cases/compile_errors/explicitly_casting_non_tag_type_to_enum.zig-2| ... | ... | @@ -12,7 +12,5 @@ export fn entry() void { |
| 12 | 12 | } |
| 13 | 13 | |
| 14 | 14 | // error |
| 15 | // backend=stage2 | |
| 16 | // target=native | |
| 17 | 15 | // |
| 18 | 16 | // :10:39: error: expected integer type, found 'f32' |
test/cases/compile_errors/export_with_empty_name_string.zig-2| ... | ... | @@ -4,7 +4,5 @@ comptime { |
| 4 | 4 | } |
| 5 | 5 | |
| 6 | 6 | // error |
| 7 | // backend=stage2 | |
| 8 | // target=native | |
| 9 | 7 | // |
| 10 | 8 | // :3:25: error: exported symbol name cannot be empty |
test/cases/compile_errors/exported_enum_without_explicit_integer_tag_type.zig-2| ... | ... | @@ -8,8 +8,6 @@ comptime { |
| 8 | 8 | } |
| 9 | 9 | |
| 10 | 10 | // error |
| 11 | // backend=stage2 | |
| 12 | // target=native | |
| 13 | 11 | // |
| 14 | 12 | // :3:5: error: unable to export type 'type' |
| 15 | 13 | // :7:5: error: unable to export type 'tmp.E' |
test/cases/compile_errors/exported_function_uses_invalid_type.zig-1| ... | ... | @@ -8,6 +8,5 @@ export fn foo() void { |
| 8 | 8 | // the original bug leading to this test occurred only with the LLVM backend. |
| 9 | 9 | |
| 10 | 10 | // error |
| 11 | // backend=stage2,llvm | |
| 12 | 11 | // |
| 13 | 12 | // :2:33: error: expected type 'u32', found '*const [11:0]u8' |
test/cases/compile_errors/extern_function_with_unspecified_calling_convention.zig-2| ... | ... | @@ -7,8 +7,6 @@ export fn entry() void { |
| 7 | 7 | } |
| 8 | 8 | |
| 9 | 9 | // error |
| 10 | // backend=stage2 | |
| 11 | // target=native | |
| 12 | 10 | // |
| 13 | 11 | // :2:8: error: extern structs cannot contain fields of type '*const fn () void' |
| 14 | 12 | // :2:8: note: extern function must specify calling convention |
test/cases/compile_errors/extern_packed_on_opaque.zig-2| ... | ... | @@ -7,8 +7,6 @@ export fn foo(x: *X, y: *Y) void { |
| 7 | 7 | } |
| 8 | 8 | |
| 9 | 9 | // error |
| 10 | // backend=stage2 | |
| 11 | // target=native | |
| 12 | 10 | // |
| 13 | 11 | // :1:11: error: opaque types do not support 'packed' or 'extern' |
| 14 | 12 | // :2:11: error: opaque types do not support 'packed' or 'extern' |
test/cases/compile_errors/extern_struct_with_extern-compatible_but_inferred_integer_tag_type.zig-2| ... | ... | @@ -38,8 +38,6 @@ export fn entry() void { |
| 38 | 38 | } |
| 39 | 39 | |
| 40 | 40 | // error |
| 41 | // backend=stage2 | |
| 42 | // target=native | |
| 43 | 41 | // |
| 44 | 42 | // :33:8: error: extern structs cannot contain fields of type 'tmp.E' |
| 45 | 43 | // :33:8: note: enum tag type 'u9' is not extern compatible |
test/cases/compile_errors/extern_struct_with_non-extern-compatible_integer_tag_type.zig-2| ... | ... | @@ -8,8 +8,6 @@ export fn entry() void { |
| 8 | 8 | } |
| 9 | 9 | |
| 10 | 10 | // error |
| 11 | // backend=stage2 | |
| 12 | // target=native | |
| 13 | 11 | // |
| 14 | 12 | // :3:8: error: extern structs cannot contain fields of type 'tmp.E' |
| 15 | 13 | // :3:8: note: enum tag type 'u31' is not extern compatible |
test/cases/compile_errors/extern_union_field_missing_type.zig-2| ... | ... | @@ -7,7 +7,5 @@ export fn entry() void { |
| 7 | 7 | } |
| 8 | 8 | |
| 9 | 9 | // error |
| 10 | // backend=stage2 | |
| 11 | // target=native | |
| 12 | 10 | // |
| 13 | 11 | // :2:5: error: union field missing type |
test/cases/compile_errors/extern_union_given_enum_tag_type.zig-2| ... | ... | @@ -14,7 +14,5 @@ export fn entry() void { |
| 14 | 14 | } |
| 15 | 15 | |
| 16 | 16 | // error |
| 17 | // backend=stage2 | |
| 18 | // target=native | |
| 19 | 17 | // |
| 20 | 18 | // :6:30: error: extern union does not support enum tag type |
test/cases/compile_errors/extern_variable_has_no_type.zig-2| ... | ... | @@ -4,7 +4,5 @@ pub export fn entry() void { |
| 4 | 4 | } |
| 5 | 5 | |
| 6 | 6 | // error |
| 7 | // backend=stage2 | |
| 8 | // target=native | |
| 9 | 7 | // |
| 10 | 8 | // :1:8: error: unable to infer variable type |
test/cases/compile_errors/extern_variable_has_non_extern_type.zig-2| ... | ... | @@ -4,8 +4,6 @@ pub export fn entry() void { |
| 4 | 4 | } |
| 5 | 5 | |
| 6 | 6 | // error |
| 7 | // backend=stage2 | |
| 8 | // target=native | |
| 9 | 7 | // |
| 10 | 8 | // :1:17: error: extern variable cannot have type 'u3' |
| 11 | 9 | // :1:17: note: only integers with 0 or power of two bits are extern compatible |
test/cases/compile_errors/extra_comma_in_destructure.zig-2| ... | ... | @@ -4,7 +4,5 @@ export fn foo() void { |
| 4 | 4 | } |
| 5 | 5 | |
| 6 | 6 | // error |
| 7 | // backend=stage2 | |
| 8 | // target=native | |
| 9 | 7 | // |
| 10 | 8 | // :2:23: error: expected expression or var decl, found '=' |
test/cases/compile_errors/fieldParentPtr-bad_field_name.zig-2| ... | ... | @@ -6,8 +6,6 @@ export fn foo(a: *i32) *Foo { |
| 6 | 6 | } |
| 7 | 7 | |
| 8 | 8 | // error |
| 9 | // backend=stage2 | |
| 10 | // target=native | |
| 11 | 9 | // |
| 12 | 10 | // :5:28: error: no field named 'a' in struct 'tmp.Foo' |
| 13 | 11 | // :1:20: note: struct declared here |
test/cases/compile_errors/fieldParentPtr-comptime_field_ptr_not_based_on_struct.zig-2| ... | ... | @@ -14,7 +14,5 @@ comptime { |
| 14 | 14 | } |
| 15 | 15 | |
| 16 | 16 | // error |
| 17 | // backend=stage2 | |
| 18 | // target=native | |
| 19 | 17 | // |
| 20 | 18 | // :12:62: error: pointer value not based on parent struct |
test/cases/compile_errors/fieldParentPtr-comptime_wrong_field_index.zig-2| ... | ... | @@ -13,8 +13,6 @@ comptime { |
| 13 | 13 | } |
| 14 | 14 | |
| 15 | 15 | // error |
| 16 | // backend=stage2 | |
| 17 | // target=native | |
| 18 | 16 | // |
| 19 | 17 | // :11:41: error: field 'b' has index '1' but pointer value is index '0' of struct 'tmp.Foo' |
| 20 | 18 | // :1:13: note: struct declared here |
test/cases/compile_errors/fieldParentPtr-field_pointer_is_not_pointer.zig-2| ... | ... | @@ -6,7 +6,5 @@ export fn foo(a: i32) *const Foo { |
| 6 | 6 | } |
| 7 | 7 | |
| 8 | 8 | // error |
| 9 | // backend=stage2 | |
| 10 | // target=native | |
| 11 | 9 | // |
| 12 | 10 | // :5:33: error: expected pointer type, found 'i32' |
test/cases/compile_errors/fieldParentPtr-non_pointer.zig-2| ... | ... | @@ -4,7 +4,5 @@ export fn foo(a: *i32) Foo { |
| 4 | 4 | } |
| 5 | 5 | |
| 6 | 6 | // error |
| 7 | // backend=stage2 | |
| 8 | // target=native | |
| 9 | 7 | // |
| 10 | 8 | // :3:12: error: expected pointer type, found 'i32' |
test/cases/compile_errors/fieldParentPtr_on_comptime_field.zig-2| ... | ... | @@ -9,8 +9,6 @@ pub export fn entry2() void { |
| 9 | 9 | } |
| 10 | 10 | |
| 11 | 11 | // error |
| 12 | // backend=stage2 | |
| 13 | // target=native | |
| 14 | 12 | // |
| 15 | 13 | // :5:5: error: no offset available for comptime field |
| 16 | 14 | // :8:29: error: cannot get @fieldParentPtr of a comptime field |
test/cases/compile_errors/field_access_of_opaque_type.zig-2| ... | ... | @@ -10,7 +10,5 @@ fn bar(x: *MyType) bool { |
| 10 | 10 | } |
| 11 | 11 | |
| 12 | 12 | // error |
| 13 | // backend=stage2 | |
| 14 | // target=native | |
| 15 | 13 | // |
| 16 | 14 | // :9:13: error: type '*tmp.MyType' does not support field access |
test/cases/compile_errors/field_access_of_slices.zig-2| ... | ... | @@ -6,8 +6,6 @@ export fn entry() void { |
| 6 | 6 | } |
| 7 | 7 | |
| 8 | 8 | // error |
| 9 | // backend=stage2 | |
| 10 | // target=native | |
| 11 | 9 | // |
| 12 | 10 | // :4:32: error: type '[]i32' has no members |
| 13 | 11 | // :4:32: note: slice values have 'len' and 'ptr' members |
test/cases/compile_errors/field_access_of_unknown_length_pointer.zig-2| ... | ... | @@ -7,7 +7,5 @@ export fn entry(foo: [*]Foo) void { |
| 7 | 7 | } |
| 8 | 8 | |
| 9 | 9 | // error |
| 10 | // backend=stage2 | |
| 11 | // target=native | |
| 12 | 10 | // |
| 13 | 11 | // :6:8: error: type '[*]tmp.Foo' does not support field access |
test/cases/compile_errors/field_access_of_wrapped_type.zig-2| ... | ... | @@ -11,8 +11,6 @@ export fn f2() void { |
| 11 | 11 | } |
| 12 | 12 | |
| 13 | 13 | // error |
| 14 | // backend=stage2 | |
| 15 | // target=native | |
| 16 | 14 | // |
| 17 | 15 | // :6:8: error: optional type '?tmp.Foo' does not support field access |
| 18 | 16 | // :6:8: note: consider using '.?', 'orelse', or 'if' |
test/cases/compile_errors/field_type_supplied_in_an_enum.zig-2| ... | ... | @@ -5,8 +5,6 @@ const Letter = enum { |
| 5 | 5 | }; |
| 6 | 6 | |
| 7 | 7 | // error |
| 8 | // backend=stage2 | |
| 9 | // target=native | |
| 10 | 8 | // |
| 11 | 9 | // :2:8: error: enum fields do not have types |
| 12 | 10 | // :1:16: note: consider 'union(enum)' here to make it a tagged union |
test/cases/compile_errors/file_level_struct_invalid_field_type.zig-2| ... | ... | @@ -11,7 +11,5 @@ comptime { |
| 11 | 11 | } |
| 12 | 12 | |
| 13 | 13 | // error |
| 14 | // backend=stage2 | |
| 15 | // target=native | |
| 16 | 14 | // |
| 17 | 15 | // :7:15: error: expected type 'type', found 'fn () type' |
test/cases/compile_errors/float exact division failure.zig	-2| ... | ... | @@ -4,7 +4,5 @@ comptime { |
| 4 | 4 | } |
| 5 | 5 | |
| 6 | 6 | // error |
| 7 | // backend=stage2 | |
| 8 | // target=native | |
| 9 | 7 | // |
| 10 | 8 | // :2:15: error: exact division produced remainder |
test/cases/compile_errors/for_discard_unbounded.zig-2| ... | ... | @@ -4,7 +4,5 @@ export fn a() void { |
| 4 | 4 | } |
| 5 | 5 | } |
| 6 | 6 | // error |
| 7 | // backend=stage2 | |
| 8 | // target=native | |
| 9 | 7 | // |
| 10 | 8 | // :2:27: error: discard of unbounded counter |
test/cases/compile_errors/for_empty.zig-2| ... | ... | @@ -5,7 +5,5 @@ export fn b() void { |
| 5 | 5 | } |
| 6 | 6 | |
| 7 | 7 | // error |
| 8 | // backend=stage2 | |
| 9 | // target=native | |
| 10 | 8 | // |
| 11 | 9 | // :2:10: error: expected expression, found ')' |
test/cases/compile_errors/for_extra_capture.zig-2| ... | ... | @@ -8,7 +8,5 @@ export fn b() void { |
| 8 | 8 | // zig fmt: on |
| 9 | 9 | |
| 10 | 10 | // error |
| 11 | // backend=stage2 | |
| 12 | // target=native | |
| 13 | 11 | // |
| 14 | 12 | // :3:21: error: extra capture in for loop |
test/cases/compile_errors/for_extra_condition.zig-2| ... | ... | @@ -5,7 +5,5 @@ export fn a() void { |
| 5 | 5 | } |
| 6 | 6 | |
| 7 | 7 | // error |
| 8 | // backend=stage2 | |
| 9 | // target=native | |
| 10 | 8 | // |
| 11 | 9 | // :2:19: error: for input is not captured |
test/cases/compile_errors/for_invalid_ranges.zig-2| ... | ... | @@ -25,8 +25,6 @@ export fn e() void { |
| 25 | 25 | } |
| 26 | 26 | |
| 27 | 27 | // error |
| 28 | // backend=stage2 | |
| 29 | // target=native | |
| 30 | 28 | // |
| 31 | 29 | // :2:13: error: expected type 'usize', found '*const [5:0]u8' |
| 32 | 30 | // :7:10: error: type 'usize' cannot represent integer value '-1' |
test/cases/compile_errors/for_loop_body_expression_ignored.zig-2| ... | ... | @@ -18,8 +18,6 @@ export fn f4() void { |
| 18 | 18 | } |
| 19 | 19 | |
| 20 | 20 | // error |
| 21 | // backend=stage2 | |
| 22 | // target=native | |
| 23 | 21 | // |
| 24 | 22 | // :5:30: error: value of type 'usize' ignored |
| 25 | 23 | // :5:30: note: all non-void values must be used |
test/cases/compile_errors/for_loop_break_value_ignored.zig-2| ... | ... | @@ -9,8 +9,6 @@ export fn f1() void { |
| 9 | 9 | } |
| 10 | 10 | |
| 11 | 11 | // error |
| 12 | // backend=stage2 | |
| 13 | // target=native | |
| 14 | 12 | // |
| 15 | 13 | // :6:5: error: incompatible types: 'usize' and 'void' |
| 16 | 14 | // :7:22: note: type 'usize' here |
test/cases/compile_errors/for_loop_error_union.zig-2| ... | ... | @@ -7,8 +7,6 @@ export fn a() void { |
| 7 | 7 | } |
| 8 | 8 | |
| 9 | 9 | // error |
| 10 | // backend=stage2 | |
| 11 | // target=native | |
| 12 | 10 | // |
| 13 | 11 | // :6:11: error: type '@typeInfo(@typeInfo(@TypeOf(tmp.b)).@"fn".return_type.?).error_union.error_set!u32' is not indexable and not a range |
| 14 | 12 | // :6:11: note: for loop operand must be a range, array, slice, tuple, or vector |
test/cases/compile_errors/for_unbounded.zig-2| ... | ... | @@ -5,7 +5,5 @@ export fn b() void { |
| 5 | 5 | } |
| 6 | 6 | |
| 7 | 7 | // error |
| 8 | // backend=stage2 | |
| 9 | // target=native | |
| 10 | 8 | // |
| 11 | 9 | // :2:5: error: unbounded for loop |
test/cases/compile_errors/function-only_builtins_outside_function.zig-2| ... | ... | @@ -47,8 +47,6 @@ comptime { |
| 47 | 47 | } |
| 48 | 48 | |
| 49 | 49 | // error |
| 50 | // backend=stage2 | |
| 51 | // target=native | |
| 52 | 50 | // |
| 53 | 51 | // :2:5: error: '@branchHint' outside function scope |
| 54 | 52 | // :6:5: error: '@src' outside function scope |
test/cases/compile_errors/function_alignment_non_power_of_2.zig-2| ... | ... | @@ -4,7 +4,5 @@ export fn entry() void { |
| 4 | 4 | } |
| 5 | 5 | |
| 6 | 6 | // error |
| 7 | // backend=stage2 | |
| 8 | // target=native | |
| 9 | 7 | // |
| 10 | 8 | // :1:23: error: alignment value '3' is not a power of two |
test/cases/compile_errors/function_alignment_on_unsupported_target.zig-1| ... | ... | @@ -1,7 +1,6 @@ |
| 1 | 1 | export fn entry() align(64) void {} |
| 2 | 2 | |
| 3 | 3 | // error |
| 4 | // backend=stage2 | |
| 5 | 4 | // target=nvptx-cuda,nvptx64-cuda,spirv32-opengl,spirv32-vulkan,spirv32-opencl,spirv64-opencl,spirv64-amdhsa,wasm32-freestanding,wasm64-freestanding |
| 6 | 5 | // |
| 7 | 6 | // :1:25: error: target does not support function alignment |
test/cases/compile_errors/function_call_assigned_to_incorrect_type.zig-2| ... | ... | @@ -7,8 +7,6 @@ fn concat() [16]f32 { |
| 7 | 7 | } |
| 8 | 8 | |
| 9 | 9 | // error |
| 10 | // backend=stage2 | |
| 11 | // target=native | |
| 12 | 10 | // |
| 13 | 11 | // :3:17: error: expected type '[4]f32', found '[16]f32' |
| 14 | 12 | // :3:17: note: destination has length 4 |
test/cases/compile_errors/function_parameter_is_opaque.zig-2| ... | ... | @@ -12,8 +12,6 @@ export fn entry3() void { |
| 12 | 12 | } |
| 13 | 13 | |
| 14 | 14 | // error |
| 15 | // backend=stage2 | |
| 16 | // target=native | |
| 17 | 15 | // |
| 18 | 16 | // :3:28: error: parameter of opaque type 'tmp.FooType' not allowed |
| 19 | 17 | // :1:17: note: opaque declared here |
test/cases/compile_errors/function_prototype_with_no_body.zig-2| ... | ... | @@ -4,7 +4,5 @@ export fn entry() void { |
| 4 | 4 | } |
| 5 | 5 | |
| 6 | 6 | // error |
| 7 | // backend=stage2 | |
| 8 | // target=native | |
| 9 | 7 | // |
| 10 | 8 | // :1:1: error: non-extern function has no body |
test/cases/compile_errors/function_ptr_alignment.zig-1| ... | ... | @@ -9,7 +9,6 @@ comptime { |
| 9 | 9 | } |
| 10 | 10 | |
| 11 | 11 | // error |
| 12 | // backend=stage2 | |
| 13 | 12 | // target=x86_64-linux |
| 14 | 13 | // |
| 15 | 14 | // :8:41: error: expected type '*align(2) const fn () void', found '*const fn () void' |
test/cases/compile_errors/function_returning_opaque_type.zig-2| ... | ... | @@ -4,8 +4,6 @@ export fn bar() FooType { |
| 4 | 4 | } |
| 5 | 5 | |
| 6 | 6 | // error |
| 7 | // backend=stage2 | |
| 8 | // target=native | |
| 9 | 7 | // |
| 10 | 8 | // :2:17: error: opaque return type 'tmp.FooType' not allowed |
| 11 | 9 | // :1:17: note: opaque declared here |
test/cases/compile_errors/function_type_coercion.zig-2| ... | ... | @@ -10,8 +10,6 @@ export fn wrong_return_type() void { |
| 10 | 10 | } |
| 11 | 11 | |
| 12 | 12 | // error |
| 13 | // backend=stage2,llvm | |
| 14 | // target=native | |
| 15 | 13 | // |
| 16 | 14 | // :3:25: error: expected type 'fn () void', found 'fn (i32) void' |
| 17 | 15 | // :3:25: note: function with 1 parameters cannot cast into a function with 0 parameters |
test/cases/compile_errors/function_type_named.zig-2| ... | ... | @@ -1,7 +1,5 @@ |
| 1 | 1 | const aFunc = fn someFunc(x: i32) void; |
| 2 | 2 | |
| 3 | 3 | // error |
| 4 | // backend=stage2 | |
| 5 | // target=native | |
| 6 | 4 | // |
| 7 | 5 | // :1:18: error: function type cannot have a name |
test/cases/compile_errors/function_with_invalid_return_type.zig-2| ... | ... | @@ -1,7 +1,5 @@ |
| 1 | 1 | export fn foo() boid {} |
| 2 | 2 | |
| 3 | 3 | // error |
| 4 | // backend=stage2 | |
| 5 | // target=native | |
| 6 | 4 | // |
| 7 | 5 | // :1:17: error: use of undeclared identifier 'boid' |
test/cases/compile_errors/generic_function_call_assigned_to_incorrect_type.zig-2| ... | ... | @@ -7,7 +7,5 @@ fn myAlloc(comptime arg: type) anyerror!arg { |
| 7 | 7 | } |
| 8 | 8 | |
| 9 | 9 | // error |
| 10 | // backend=stage2 | |
| 11 | // target=native | |
| 12 | 10 | // |
| 13 | 11 | // :3:18: error: expected type '[]i32', found 'anyerror!i32' |
test/cases/compile_errors/generic_instantiation_failure.zig-2| ... | ... | @@ -19,8 +19,6 @@ pub export fn entry() void { |
| 19 | 19 | } |
| 20 | 20 | |
| 21 | 21 | // error |
| 22 | // backend=stage2 | |
| 23 | // target=native | |
| 24 | 22 | // |
| 25 | 23 | // :18:43: error: value of type 'type' ignored |
| 26 | 24 | // :18:43: note: all non-void values must be used |
test/cases/compile_errors/global_var_struct_init_in_comptime_block.zig-2| ... | ... | @@ -7,8 +7,6 @@ comptime { |
| 7 | 7 | } |
| 8 | 8 | |
| 9 | 9 | // error |
| 10 | // backend=stage2 | |
| 11 | // target=native | |
| 12 | 10 | // |
| 13 | 11 | // :6:17: error: unable to evaluate comptime expression |
| 14 | 12 | // :6:17: note: operation is runtime due to this operand |
test/cases/compile_errors/global_variable_alignment_non_power_of_2.zig-2| ... | ... | @@ -4,7 +4,5 @@ export fn entry() usize { |
| 4 | 4 | } |
| 5 | 5 | |
| 6 | 6 | // error |
| 7 | // backend=stage2 | |
| 8 | // target=native | |
| 9 | 7 | // |
| 10 | 8 | // :1:32: error: alignment value '3' is not a power of two |
test/cases/compile_errors/hasDecl_with_non-container.zig-2| ... | ... | @@ -3,7 +3,5 @@ export fn entry() void { |
| 3 | 3 | } |
| 4 | 4 | |
| 5 | 5 | // error |
| 6 | // backend=stage2 | |
| 7 | // target=native | |
| 8 | 6 | // |
| 9 | 7 | // :2:18: error: expected struct, enum, union, or opaque; found 'i32' |
test/cases/compile_errors/helpful_return_type_error_message.zig-2| ... | ... | @@ -16,8 +16,6 @@ export fn quux() u32 { |
| 16 | 16 | } |
| 17 | 17 | |
| 18 | 18 | // error |
| 19 | // backend=stage2 | |
| 20 | // target=native | |
| 21 | 19 | // |
| 22 | 20 | // :2:18: error: expected type 'u32', found 'error{Ohno}' |
| 23 | 21 | // :1:17: note: function cannot return an error |
test/cases/compile_errors/if_condition_is_bool_not_int.zig-2| ... | ... | @@ -7,8 +7,6 @@ export fn bar() void { |
| 7 | 7 | } |
| 8 | 8 | |
| 9 | 9 | // error |
| 10 | // backend=stage2 | |
| 11 | // target=native | |
| 12 | 10 | // |
| 13 | 11 | // :2:9: error: expected type 'bool', found 'comptime_int' |
| 14 | 12 | // :6:18: error: expected type 'bool', found 'comptime_int' |
test/cases/compile_errors/ignored_assert-err-ok_return_value.zig-2| ... | ... | @@ -6,8 +6,6 @@ fn bar() anyerror!i32 { |
| 6 | 6 | } |
| 7 | 7 | |
| 8 | 8 | // error |
| 9 | // backend=stage2 | |
| 10 | // target=native | |
| 11 | 9 | // |
| 12 | 10 | // :2:11: error: value of type 'i32' ignored |
| 13 | 11 | // :2:11: note: all non-void values must be used |
test/cases/compile_errors/ignored_comptime_statement_value.zig-2| ... | ... | @@ -5,8 +5,6 @@ export fn foo() void { |
| 5 | 5 | } |
| 6 | 6 | |
| 7 | 7 | // error |
| 8 | // backend=stage2 | |
| 9 | // target=native | |
| 10 | 8 | // |
| 11 | 9 | // :3:9: error: value of type 'comptime_int' ignored |
| 12 | 10 | // :3:9: note: all non-void values must be used |
test/cases/compile_errors/ignored_comptime_value.zig-2| ... | ... | @@ -9,8 +9,6 @@ fn bar() u8 { |
| 9 | 9 | } |
| 10 | 10 | |
| 11 | 11 | // error |
| 12 | // backend=stage2 | |
| 13 | // target=native | |
| 14 | 12 | // |
| 15 | 13 | // :2:5: error: value of type 'comptime_int' ignored |
| 16 | 14 | // :2:5: note: all non-void values must be used |
test/cases/compile_errors/ignored_deferred_function_call.zig-2| ... | ... | @@ -13,8 +13,6 @@ fn bar2() anyerror { |
| 13 | 13 | } |
| 14 | 14 | |
| 15 | 15 | // error |
| 16 | // backend=stage2 | |
| 17 | // target=native | |
| 18 | 16 | // |
| 19 | 17 | // :2:14: error: error union is ignored |
| 20 | 18 | // :2:14: note: consider using 'try', 'catch', or 'if' |
test/cases/compile_errors/ignored_deferred_statement_value.zig-2| ... | ... | @@ -5,8 +5,6 @@ export fn foo() void { |
| 5 | 5 | } |
| 6 | 6 | |
| 7 | 7 | // error |
| 8 | // backend=stage2 | |
| 9 | // target=native | |
| 10 | 8 | // |
| 11 | 9 | // :3:9: error: value of type 'comptime_int' ignored |
| 12 | 10 | // :3:9: note: all non-void values must be used |
test/cases/compile_errors/ignored_expression_in_while_continuation.zig-2| ... | ... | @@ -23,8 +23,6 @@ fn bad2() anyerror { |
| 23 | 23 | } |
| 24 | 24 | |
| 25 | 25 | // error |
| 26 | // backend=stage2 | |
| 27 | // target=native | |
| 28 | 26 | // |
| 29 | 27 | // :2:24: error: error union is ignored |
| 30 | 28 | // :2:24: note: consider using 'try', 'catch', or 'if' |
test/cases/compile_errors/ignored_return_value.zig-2| ... | ... | @@ -6,8 +6,6 @@ fn bar() i32 { |
| 6 | 6 | } |
| 7 | 7 | |
| 8 | 8 | // error |
| 9 | // backend=stage2 | |
| 10 | // target=native | |
| 11 | 9 | // |
| 12 | 10 | // :2:8: error: value of type 'i32' ignored |
| 13 | 11 | // :2:8: note: all non-void values must be used |
test/cases/compile_errors/ignored_statement_value.zig-2| ... | ... | @@ -3,8 +3,6 @@ export fn foo() void { |
| 3 | 3 | } |
| 4 | 4 | |
| 5 | 5 | // error |
| 6 | // backend=stage2 | |
| 7 | // target=native | |
| 8 | 6 | // |
| 9 | 7 | // :2:5: error: value of type 'comptime_int' ignored |
| 10 | 8 | // :2:5: note: all non-void values must be used |
test/cases/compile_errors/illegal_comparison_of_types.zig-2| ... | ... | @@ -17,8 +17,6 @@ export fn entry2() usize { |
| 17 | 17 | } |
| 18 | 18 | |
| 19 | 19 | // error |
| 20 | // backend=stage2 | |
| 21 | // target=native | |
| 22 | 20 | // |
| 23 | 21 | // :2:14: error: operator == not allowed for type '[]u8' |
| 24 | 22 | // :9:16: error: operator == not allowed for type 'tmp.EnumWithData' |
test/cases/compile_errors/illegal_operation_on_logical_ptr.zig-1| ... | ... | @@ -35,7 +35,6 @@ export fn ptrIntArithmetic() void { |
| 35 | 35 | } |
| 36 | 36 | |
| 37 | 37 | // error |
| 38 | // backend=stage2 | |
| 39 | 38 | // target=spirv64-vulkan |
| 40 | 39 | // |
| 41 | 40 | // :3:8: error: illegal operation on logical pointer of type '[*]u8' |
test/cases/compile_errors/implicit_array_ptr_cast_sentinel_mismatch.zig-2| ... | ... | @@ -12,8 +12,6 @@ pub export fn entry1() void { |
| 12 | 12 | } |
| 13 | 13 | |
| 14 | 14 | // error |
| 15 | // backend=stage2 | |
| 16 | // target=native | |
| 17 | 15 | // |
| 18 | 16 | // :2:12: error: expected type '[:255]const u8', found '*const [4:0]u8' |
| 19 | 17 | // :2:12: note: pointer sentinel '0' cannot cast into pointer sentinel '255' |
test/cases/compile_errors/implicit_cast_between_C_pointer_and_Zig_pointer-bad_const-align-child.zig-2| ... | ... | @@ -30,8 +30,6 @@ export fn f() void { |
| 30 | 30 | } |
| 31 | 31 | |
| 32 | 32 | // error |
| 33 | // backend=stage2 | |
| 34 | // target=native | |
| 35 | 33 | // |
| 36 | 34 | // :3:27: error: expected type '*align(4) u8', found '[*c]u8' |
| 37 | 35 | // :3:27: note: pointer alignment '1' cannot cast into pointer alignment '4' |
test/cases/compile_errors/implicit_cast_const_array_to_mutable_slice.zig-2| ... | ... | @@ -20,8 +20,6 @@ export fn entry3() void { |
| 20 | 20 | } |
| 21 | 21 | |
| 22 | 22 | // error |
| 23 | // backend=stage2 | |
| 24 | // target=native | |
| 25 | 23 | // |
| 26 | 24 | // :3:26: error: expected type '[]u8', found '*const [1]u8' |
| 27 | 25 | // :3:26: note: cast discards const qualifier |
test/cases/compile_errors/implicit_cast_from_array_to_mutable_slice.zig-2| ... | ... | @@ -7,7 +7,5 @@ export fn entry() void { |
| 7 | 7 | } |
| 8 | 8 | |
| 9 | 9 | // error |
| 10 | // backend=stage2 | |
| 11 | // target=native | |
| 12 | 10 | // |
| 13 | 11 | // :6:9: error: array literal requires address-of operator (&) to coerce to slice type '[]i32' |
test/cases/compile_errors/implicit_cast_from_f64_to_f32.zig-2| ... | ... | @@ -11,8 +11,6 @@ export fn entry2() void { |
| 11 | 11 | } |
| 12 | 12 | |
| 13 | 13 | // error |
| 14 | // backend=stage2 | |
| 15 | // target=native | |
| 16 | 14 | // |
| 17 | 15 | // :2:14: error: expected type 'f32', found 'f64' |
| 18 | 16 | // :9:19: error: expected type 'f32', found 'f64' |
test/cases/compile_errors/implicit_cast_of_error_set_not_a_subset.zig-2| ... | ... | @@ -9,8 +9,6 @@ fn foo(set1: Set1) void { |
| 9 | 9 | } |
| 10 | 10 | |
| 11 | 11 | // error |
| 12 | // backend=stage2 | |
| 13 | // target=native | |
| 14 | 12 | // |
| 15 | 13 | // :7:21: error: expected type 'error{A,C}', found 'error{A,B}' |
| 16 | 14 | // :7:21: note: 'error.B' not a member of destination error set |
test/cases/compile_errors/implicit_cast_to_c_ptr_from_int.zig-2| ... | ... | @@ -7,8 +7,6 @@ export fn entry2() void { |
| 7 | 7 | } |
| 8 | 8 | |
| 9 | 9 | // error |
| 10 | // backend=stage2 | |
| 11 | // target=native | |
| 12 | 10 | // |
| 13 | 11 | // :3:21: error: expected type '[*c]u8', found 'u65' |
| 14 | 12 | // :3:21: note: unsigned 64-bit int cannot represent all possible unsigned 65-bit values |
test/cases/compile_errors/implicit_casting_C_pointers_which_would_mess_up_null_semantics.zig-2| ... | ... | @@ -20,8 +20,6 @@ export fn entry2() void { |
| 20 | 20 | } |
| 21 | 21 | |
| 22 | 22 | // error |
| 23 | // backend=stage2 | |
| 24 | // target=native | |
| 25 | 23 | // |
| 26 | 24 | // :6:24: error: expected type '*const [*]const u8', found '[*c]const [*c]const u8' |
| 27 | 25 | // :6:24: note: '[*c]const [*c]const u8' could have null values which are illegal in type '*const [*]const u8' |
test/cases/compile_errors/implicit_casting_null_c_pointer_to_zig_pointer.zig-2| ... | ... | @@ -6,7 +6,5 @@ comptime { |
| 6 | 6 | } |
| 7 | 7 | |
| 8 | 8 | // error |
| 9 | // backend=stage2 | |
| 10 | // target=native | |
| 11 | 9 | // |
| 12 | 10 | // :3:26: error: null pointer casted to type '*u8' |
test/cases/compile_errors/implicit_dependency_on_libc.zig-1| ... | ... | @@ -4,7 +4,6 @@ export fn entry() void { |
| 4 | 4 | } |
| 5 | 5 | |
| 6 | 6 | // error |
| 7 | // backend=stage2 | |
| 8 | 7 | // target=native-linux |
| 9 | 8 | // |
| 10 | 9 | // :1:8: error: dependency on libc must be explicitly specified in the build command |
test/cases/compile_errors/implicit_semicolon-block_expr.zig-2| ... | ... | @@ -8,7 +8,5 @@ export fn entry() void { |
| 8 | 8 | } |
| 9 | 9 | |
| 10 | 10 | // error |
| 11 | // backend=stage2 | |
| 12 | // target=native | |
| 13 | 11 | // |
| 14 | 12 | // :4:11: error: expected ';' after statement |
test/cases/compile_errors/implicit_semicolon-block_statement.zig-2| ... | ... | @@ -8,7 +8,5 @@ export fn entry() void { |
| 8 | 8 | } |
| 9 | 9 | |
| 10 | 10 | // error |
| 11 | // backend=stage2 | |
| 12 | // target=native | |
| 13 | 11 | // |
| 14 | 12 | // :4:9: error: expected ';' after statement |
test/cases/compile_errors/implicit_semicolon-comptime_expression.zig-2| ... | ... | @@ -8,7 +8,5 @@ export fn entry() void { |
| 8 | 8 | } |
| 9 | 9 | |
| 10 | 10 | // error |
| 11 | // backend=stage2 | |
| 12 | // target=native | |
| 13 | 11 | // |
| 14 | 12 | // :4:20: error: expected ';' after statement |
test/cases/compile_errors/implicit_semicolon-comptime_statement.zig-2| ... | ... | @@ -8,7 +8,5 @@ export fn entry() void { |
| 8 | 8 | } |
| 9 | 9 | |
| 10 | 10 | // error |
| 11 | // backend=stage2 | |
| 12 | // target=native | |
| 13 | 11 | // |
| 14 | 12 | // :4:18: error: expected ';' after statement |
test/cases/compile_errors/implicit_semicolon-defer.zig-2| ... | ... | @@ -8,7 +8,5 @@ export fn entry() void { |
| 8 | 8 | } |
| 9 | 9 | |
| 10 | 10 | // error |
| 11 | // backend=stage2 | |
| 12 | // target=native | |
| 13 | 11 | // |
| 14 | 12 | // :4:15: error: expected ';' after statement |
test/cases/compile_errors/implicit_semicolon-for_expression.zig-2| ... | ... | @@ -9,7 +9,5 @@ export fn entry() void { |
| 9 | 9 | fn foo() void {} |
| 10 | 10 | |
| 11 | 11 | // error |
| 12 | // backend=stage2 | |
| 13 | // target=native | |
| 14 | 12 | // |
| 15 | 13 | // :4:26: error: expected ';' after statement |
test/cases/compile_errors/implicit_semicolon-for_statement.zig-2| ... | ... | @@ -9,7 +9,5 @@ export fn entry() void { |
| 9 | 9 | fn foo() void {} |
| 10 | 10 | |
| 11 | 11 | // error |
| 12 | // backend=stage2 | |
| 13 | // target=native | |
| 14 | 12 | // |
| 15 | 13 | // :4:24: error: expected ';' or 'else' after statement |
test/cases/compile_errors/implicit_semicolon-if-else-if-else_expression.zig-2| ... | ... | @@ -8,7 +8,5 @@ export fn entry() void { |
| 8 | 8 | } |
| 9 | 9 | |
| 10 | 10 | // error |
| 11 | // backend=stage2 | |
| 12 | // target=native | |
| 13 | 11 | // |
| 14 | 12 | // :4:45: error: expected ';' after statement |
test/cases/compile_errors/implicit_semicolon-if-else-if-else_statement.zig-2| ... | ... | @@ -8,7 +8,5 @@ export fn entry() void { |
| 8 | 8 | } |
| 9 | 9 | |
| 10 | 10 | // error |
| 11 | // backend=stage2 | |
| 12 | // target=native | |
| 13 | 11 | // |
| 14 | 12 | // :4:47: error: expected ';' after statement |
test/cases/compile_errors/implicit_semicolon-if-else-if_expression.zig-2| ... | ... | @@ -8,7 +8,5 @@ export fn entry() void { |
| 8 | 8 | } |
| 9 | 9 | |
| 10 | 10 | // error |
| 11 | // backend=stage2 | |
| 12 | // target=native | |
| 13 | 11 | // |
| 14 | 12 | // :4:37: error: expected ';' after statement |
test/cases/compile_errors/implicit_semicolon-if-else-if_statement.zig-2| ... | ... | @@ -8,7 +8,5 @@ export fn entry() void { |
| 8 | 8 | } |
| 9 | 9 | |
| 10 | 10 | // error |
| 11 | // backend=stage2 | |
| 12 | // target=native | |
| 13 | 11 | // |
| 14 | 12 | // :4:37: error: expected ';' or 'else' after statement |
test/cases/compile_errors/implicit_semicolon-if-else_expression.zig-2| ... | ... | @@ -8,7 +8,5 @@ export fn entry() void { |
| 8 | 8 | } |
| 9 | 9 | |
| 10 | 10 | // error |
| 11 | // backend=stage2 | |
| 12 | // target=native | |
| 13 | 11 | // |
| 14 | 12 | // :4:28: error: expected ';' after statement |
test/cases/compile_errors/implicit_semicolon-if-else_statement.zig-2| ... | ... | @@ -8,7 +8,5 @@ export fn entry() void { |
| 8 | 8 | } |
| 9 | 9 | |
| 10 | 10 | // error |
| 11 | // backend=stage2 | |
| 12 | // target=native | |
| 13 | 11 | // |
| 14 | 12 | // :4:28: error: expected ';' after statement |
test/cases/compile_errors/implicit_semicolon-if_expression.zig-2| ... | ... | @@ -8,7 +8,5 @@ export fn entry() void { |
| 8 | 8 | } |
| 9 | 9 | |
| 10 | 10 | // error |
| 11 | // backend=stage2 | |
| 12 | // target=native | |
| 13 | 11 | // |
| 14 | 12 | // :4:20: error: expected ';' after statement |
test/cases/compile_errors/implicit_semicolon-if_statement.zig-2| ... | ... | @@ -8,7 +8,5 @@ export fn entry() void { |
| 8 | 8 | } |
| 9 | 9 | |
| 10 | 10 | // error |
| 11 | // backend=stage2 | |
| 12 | // target=native | |
| 13 | 11 | // |
| 14 | 12 | // :4:18: error: expected ';' or 'else' after statement |
test/cases/compile_errors/implicit_semicolon-test_expression.zig-2| ... | ... | @@ -9,7 +9,5 @@ export fn entry() void { |
| 9 | 9 | fn foo() void {} |
| 10 | 10 | |
| 11 | 11 | // error |
| 12 | // backend=stage2 | |
| 13 | // target=native | |
| 14 | 12 | // |
| 15 | 13 | // :4:26: error: expected ';' after statement |
test/cases/compile_errors/implicit_semicolon-test_statement.zig-2| ... | ... | @@ -9,7 +9,5 @@ export fn entry() void { |
| 9 | 9 | fn foo() void {} |
| 10 | 10 | |
| 11 | 11 | // error |
| 12 | // backend=stage2 | |
| 13 | // target=native | |
| 14 | 12 | // |
| 15 | 13 | // :4:24: error: expected ';' or 'else' after statement |
test/cases/compile_errors/implicit_semicolon-while-continue_expression.zig-2| ... | ... | @@ -8,7 +8,5 @@ export fn entry() void { |
| 8 | 8 | } |
| 9 | 9 | |
| 10 | 10 | // error |
| 11 | // backend=stage2 | |
| 12 | // target=native | |
| 13 | 11 | // |
| 14 | 12 | // :4:28: error: expected ';' after statement |
test/cases/compile_errors/implicit_semicolon-while-continue_statement.zig-2| ... | ... | @@ -8,7 +8,5 @@ export fn entry() void { |
| 8 | 8 | } |
| 9 | 9 | |
| 10 | 10 | // error |
| 11 | // backend=stage2 | |
| 12 | // target=native | |
| 13 | 11 | // |
| 14 | 12 | // :4:26: error: expected ';' or 'else' after statement |
test/cases/compile_errors/implicit_semicolon-while_expression.zig-2| ... | ... | @@ -8,7 +8,5 @@ export fn entry() void { |
| 8 | 8 | } |
| 9 | 9 | |
| 10 | 10 | // error |
| 11 | // backend=stage2 | |
| 12 | // target=native | |
| 13 | 11 | // |
| 14 | 12 | // :4:23: error: expected ';' after statement |
test/cases/compile_errors/implicit_semicolon-while_statement.zig-2| ... | ... | @@ -8,7 +8,5 @@ export fn entry() void { |
| 8 | 8 | } |
| 9 | 9 | |
| 10 | 10 | // error |
| 11 | // backend=stage2 | |
| 12 | // target=native | |
| 13 | 11 | // |
| 14 | 12 | // :4:18: error: expected ';' or 'else' after statement |
test/cases/compile_errors/implicitly_casting_enum_to_tag_type.zig-2| ... | ... | @@ -11,8 +11,6 @@ export fn entry() void { |
| 11 | 11 | } |
| 12 | 12 | |
| 13 | 13 | // error |
| 14 | // backend=stage2 | |
| 15 | // target=native | |
| 16 | 14 | // |
| 17 | 15 | // :9:22: error: expected type 'u2', found 'tmp.Small' |
| 18 | 16 | // :1:15: note: enum declared here |
test/cases/compile_errors/implicitly_increasing_pointer_alignment.zig-2| ... | ... | @@ -13,8 +13,6 @@ fn bar(x: *u32) void { |
| 13 | 13 | } |
| 14 | 14 | |
| 15 | 15 | // error |
| 16 | // backend=stage2 | |
| 17 | // target=native | |
| 18 | 16 | // |
| 19 | 17 | // :8:9: error: expected type '*u32', found '*align(1) u32' |
| 20 | 18 | // :8:9: note: pointer alignment '1' cannot cast into pointer alignment '4' |
test/cases/compile_errors/implicitly_increasing_slice_alignment.zig-2| ... | ... | @@ -14,8 +14,6 @@ fn bar(x: []u32) void { |
| 14 | 14 | } |
| 15 | 15 | |
| 16 | 16 | // error |
| 17 | // backend=stage2 | |
| 18 | // target=native | |
| 19 | 17 | // |
| 20 | 18 | // :9:22: error: expected type '*[1]u32', found '*align(1) u32' |
| 21 | 19 | // :9:22: note: pointer alignment '1' cannot cast into pointer alignment '4' |
test/cases/compile_errors/in_memory_coerce_vector_to_array.zig-2| ... | ... | @@ -8,8 +8,6 @@ fn bar() anyerror!@Vector(4, u32) { |
| 8 | 8 | return .{ 1, 2, 3, 4 }; |
| 9 | 9 | } |
| 10 | 10 | // error |
| 11 | // backend=stage2 | |
| 12 | // target=native | |
| 13 | 11 | // |
| 14 | 12 | // :5:15: error: expected type 'anyerror![4]u32', found 'anyerror!@Vector(4, u32)' |
| 15 | 13 | // :5:15: note: error union payload '@Vector(4, u32)' cannot cast into error union payload '[4]u32' |
test/cases/compile_errors/incompatible sub-byte fields.zig	-2| ... | ... | @@ -22,8 +22,6 @@ export fn entry() void { |
| 22 | 22 | } |
| 23 | 23 | } |
| 24 | 24 | // error |
| 25 | // backend=stage2 | |
| 26 | // target=native | |
| 27 | 25 | // |
| 28 | 26 | // :15:17: error: incompatible types: '*align(1:0:1) u2' and '*align(2:8:2) u2' |
| 29 | 27 | // :16:14: note: type '*align(1:0:1) u2' here |
test/cases/compile_errors/incompatible_sentinels.zig-2| ... | ... | @@ -16,8 +16,6 @@ export fn entry4() void { |
| 16 | 16 | } |
| 17 | 17 | |
| 18 | 18 | // error |
| 19 | // backend=stage2 | |
| 20 | // target=native | |
| 21 | 19 | // |
| 22 | 20 | // :4:12: error: expected type '[*:0]u8', found '[*:255]u8' |
| 23 | 21 | // :4:12: note: pointer sentinel '255' cannot cast into pointer sentinel '0' |
test/cases/compile_errors/incorrect_return_type.zig-2| ... | ... | @@ -15,8 +15,6 @@ fn bar() B { |
| 15 | 15 | } |
| 16 | 16 | |
| 17 | 17 | // error |
| 18 | // backend=stage2 | |
| 19 | // target=native | |
| 20 | 18 | // |
| 21 | 19 | // :8:15: error: expected type 'tmp.A', found 'tmp.B' |
| 22 | 20 | // :10:11: note: struct declared here |
test/cases/compile_errors/incorrect_type_to_memset_memcpy.zig-2| ... | ... | @@ -63,8 +63,6 @@ pub export fn memset_array() void { |
| 63 | 63 | } |
| 64 | 64 | |
| 65 | 65 | // error |
| 66 | // backend=stage2 | |
| 67 | // target=native | |
| 68 | 66 | // |
| 69 | 67 | // :5:5: error: unknown copy length |
| 70 | 68 | // :5:18: note: destination type '[*]u8' provides no length |
test/cases/compile_errors/increase_pointer_alignment_in_ptrCast.zig-2| ... | ... | @@ -5,8 +5,6 @@ export fn entry() u32 { |
| 5 | 5 | } |
| 6 | 6 | |
| 7 | 7 | // error |
| 8 | // backend=stage2 | |
| 9 | // target=native | |
| 10 | 8 | // |
| 11 | 9 | // :3:23: error: @ptrCast increases pointer alignment |
| 12 | 10 | // :3:32: note: '*u8' has alignment '1' |
test/cases/compile_errors/indexing_an_array_of_size_zero.zig-2| ... | ... | @@ -5,7 +5,5 @@ export fn foo() void { |
| 5 | 5 | } |
| 6 | 6 | |
| 7 | 7 | // error |
| 8 | // backend=stage2 | |
| 9 | // target=native | |
| 10 | 8 | // |
| 11 | 9 | // :3:27: error: indexing into empty array is not allowed |
test/cases/compile_errors/indexing_an_array_of_size_zero_with_runtime_index.zig-2| ... | ... | @@ -7,7 +7,5 @@ export fn foo() void { |
| 7 | 7 | } |
| 8 | 8 | |
| 9 | 9 | // error |
| 10 | // backend=stage2 | |
| 11 | // target=native | |
| 12 | 10 | // |
| 13 | 11 | // :5:27: error: indexing into empty array is not allowed |
test/cases/compile_errors/indexing_non-tuple_struct.zig-2| ... | ... | @@ -5,8 +5,6 @@ export fn a() void { |
| 5 | 5 | } |
| 6 | 6 | |
| 7 | 7 | // error |
| 8 | // backend=stage2 | |
| 9 | // target=native | |
| 10 | 8 | // |
| 11 | 9 | // :4:6: error: type 'tmp.a.S' does not support indexing |
| 12 | 10 | // :4:6: note: operand must be an array, slice, tuple, or vector |
test/cases/compile_errors/indexing_single-item_pointer.zig-2| ... | ... | @@ -3,8 +3,6 @@ export fn entry(ptr: *i32) i32 { |
| 3 | 3 | } |
| 4 | 4 | |
| 5 | 5 | // error |
| 6 | // backend=stage2 | |
| 7 | // target=native | |
| 8 | 6 | // |
| 9 | 7 | // :2:15: error: type '*i32' does not support indexing |
| 10 | 8 | // :2:15: note: operand must be an array, slice, tuple, or vector |
test/cases/compile_errors/indirect_struct_loop.zig-2| ... | ... | @@ -12,7 +12,5 @@ export fn entry() usize { |
| 12 | 12 | } |
| 13 | 13 | |
| 14 | 14 | // error |
| 15 | // backend=stage2 | |
| 16 | // target=native | |
| 17 | 15 | // |
| 18 | 16 | // :1:11: error: struct 'tmp.A' depends on itself |
test/cases/compile_errors/inferred_array_size_invalid_here.zig-2| ... | ... | @@ -9,8 +9,6 @@ export fn entry2() void { |
| 9 | 9 | } |
| 10 | 10 | |
| 11 | 11 | // error |
| 12 | // backend=stage2 | |
| 13 | // target=native | |
| 14 | 12 | // |
| 15 | 13 | // :2:16: error: unable to infer array size |
| 16 | 14 | // :6:35: error: unable to infer array size |
test/cases/compile_errors/initializing_array_with_struct_syntax.zig-2| ... | ... | @@ -4,7 +4,5 @@ export fn entry() void { |
| 4 | 4 | } |
| 5 | 5 | |
| 6 | 6 | // error |
| 7 | // backend=stage2 | |
| 8 | // target=native | |
| 9 | 7 | // |
| 10 | 8 | // :2:15: error: initializing array with struct syntax |
test/cases/compile_errors/inline_underscore_prong.zig-2| ... | ... | @@ -9,7 +9,5 @@ pub export fn entry() void { |
| 9 | 9 | } |
| 10 | 10 | |
| 11 | 11 | // error |
| 12 | // backend=stage2 | |
| 13 | // target=native | |
| 14 | 12 | // |
| 15 | 13 | // :7:16: error: cannot inline '_' prong |
test/cases/compile_errors/instantiating_an_undefined_value_for_an_invalid_struct_that_contains_itself.zig-2| ... | ... | @@ -9,7 +9,5 @@ export fn entry() usize { |
| 9 | 9 | } |
| 10 | 10 | |
| 11 | 11 | // error |
| 12 | // backend=stage2 | |
| 13 | // target=native | |
| 14 | 12 | // |
| 15 | 13 | // :1:13: error: struct 'tmp.Foo' depends on itself |
test/cases/compile_errors/instantiating_an_undefined_value_for_an_invalid_union_that_contains_itself.zig-2| ... | ... | @@ -9,7 +9,5 @@ export fn entry() usize { |
| 9 | 9 | } |
| 10 | 10 | |
| 11 | 11 | // error |
| 12 | // backend=stage2 | |
| 13 | // target=native | |
| 14 | 12 | // |
| 15 | 13 | // :1:13: error: union 'tmp.Foo' depends on itself |
test/cases/compile_errors/intFromFloat_comptime_safety.zig-2| ... | ... | @@ -9,8 +9,6 @@ comptime { |
| 9 | 9 | } |
| 10 | 10 | |
| 11 | 11 | // error |
| 12 | // backend=stage2 | |
| 13 | // target=native | |
| 14 | 12 | // |
| 15 | 13 | // :2:31: error: float value '-129.10000610351562' cannot be stored in integer type 'i8' |
| 16 | 14 | // :5:31: error: float value '-1.100000023841858' cannot be stored in integer type 'u8' |
test/cases/compile_errors/intFromPtr_0_to_non_optional_pointer.zig-2| ... | ... | @@ -4,7 +4,5 @@ export fn entry() void { |
| 4 | 4 | } |
| 5 | 5 | |
| 6 | 6 | // error |
| 7 | // backend=stage2 | |
| 8 | // target=native | |
| 9 | 7 | // |
| 10 | 8 | // :2:33: error: pointer type '*i32' does not allow address zero |
test/cases/compile_errors/int_from_enum_undefined.zig-2| ... | ... | @@ -6,8 +6,6 @@ export fn a() void { |
| 6 | 6 | } |
| 7 | 7 | |
| 8 | 8 | // error |
| 9 | // backend=stage2 | |
| 10 | // target=native | |
| 11 | 9 | // |
| 12 | 10 | // :5:22: error: cannot use @intFromEnum on empty enum 'tmp.a.E' |
| 13 | 11 | // :2:15: note: enum declared here |
test/cases/compile_errors/int_from_ptr_to_optional.zig-2| ... | ... | @@ -5,8 +5,6 @@ comptime { |
| 5 | 5 | } |
| 6 | 6 | |
| 7 | 7 | // error |
| 8 | // backend=stage2 | |
| 9 | // target=native | |
| 10 | 8 | // |
| 11 | 9 | // :4:9: error: unable to evaluate comptime expression |
| 12 | 10 | // :4:21: note: operation is runtime due to this operand |
test/cases/compile_errors/int_to_err_global_invalid_number.zig-2| ... | ... | @@ -9,7 +9,5 @@ comptime { |
| 9 | 9 | } |
| 10 | 10 | |
| 11 | 11 | // error |
| 12 | // backend=stage2 | |
| 13 | // target=native | |
| 14 | 12 | // |
| 15 | 13 | // :7:27: error: integer value '3' represents no error |
test/cases/compile_errors/int_to_err_non_global_invalid_number.zig-2| ... | ... | @@ -13,7 +13,5 @@ comptime { |
| 13 | 13 | } |
| 14 | 14 | |
| 15 | 15 | // error |
| 16 | // backend=stage2 | |
| 17 | // target=native | |
| 18 | 16 | // |
| 19 | 17 | // :11:21: error: 'error.B' not a member of error set 'error{A,C}' |
test/cases/compile_errors/integer_cast_truncates_bits.zig-2| ... | ... | @@ -20,8 +20,6 @@ export fn entry4() void { |
| 20 | 20 | } |
| 21 | 21 | |
| 22 | 22 | // error |
| 23 | // backend=stage2 | |
| 24 | // target=native | |
| 25 | 23 | // |
| 26 | 24 | // :3:31: error: type 'u8' cannot represent integer value '300' |
| 27 | 25 | // :8:22: error: type 'u8' cannot represent integer value '300' |
test/cases/compile_errors/integer_overflow_error.zig-2| ... | ... | @@ -4,7 +4,5 @@ export fn entry() usize { |
| 4 | 4 | } |
| 5 | 5 | |
| 6 | 6 | // error |
| 7 | // backend=stage2 | |
| 8 | // target=native | |
| 9 | 7 | // |
| 10 | 8 | // :1:15: error: type 'u8' cannot represent integer value '300' |
test/cases/compile_errors/integer_underflow_error.zig-2| ... | ... | @@ -3,7 +3,5 @@ export fn entry() void { |
| 3 | 3 | } |
| 4 | 4 | |
| 5 | 5 | // error |
| 6 | // backend=stage2 | |
| 7 | // target=native | |
| 8 | 6 | // |
| 9 | 7 | // :2:84: error: overflow of integer type 'usize' with value '-1' |
test/cases/compile_errors/invalid_address_space_coercion.zig-1| ... | ... | @@ -7,7 +7,6 @@ pub fn main() void { |
| 7 | 7 | |
| 8 | 8 | // error |
| 9 | 9 | // output_mode=Exe |
| 10 | // backend=stage2,llvm | |
| 11 | 10 | // target=x86_64-linux,x86_64-macos |
| 12 | 11 | // |
| 13 | 12 | // :2:12: error: expected type '*i32', found '*addrspace(.gs) i32' |
test/cases/compile_errors/invalid_array_assignment_with_valid_elems.zig-2| ... | ... | @@ -5,7 +5,5 @@ export fn a() void { |
| 5 | 5 | } |
| 6 | 6 | |
| 7 | 7 | // error |
| 8 | // backend=stage2 | |
| 9 | // target=native | |
| 10 | 8 | // |
| 11 | 9 | // 3:23: error: expected type '[3]i32', found '[3]u16' |
test/cases/compile_errors/invalid_array_elem_ty.zig-2| ... | ... | @@ -6,7 +6,5 @@ pub export fn entry() void { |
| 6 | 6 | } |
| 7 | 7 | |
| 8 | 8 | // error |
| 9 | // target=native | |
| 10 | // backend=stage2 | |
| 11 | 9 | // |
| 12 | 10 | // :5:12: error: expected type 'type', found 'fn () type' |
test/cases/compile_errors/invalid_array_elem_type.zig-2| ... | ... | @@ -6,8 +6,6 @@ comptime { |
| 6 | 6 | } |
| 7 | 7 | |
| 8 | 8 | // error |
| 9 | // backend=stage2 | |
| 10 | // target=native | |
| 11 | 9 | // |
| 12 | 10 | // :2:12: error: array of opaque type 'anyopaque' not allowed |
| 13 | 11 | // :5:12: error: array of 'noreturn' not allowed |
test/cases/compile_errors/invalid_assignments.zig-2| ... | ... | @@ -11,8 +11,6 @@ export fn entry4() void { |
| 11 | 11 | } |
| 12 | 12 | |
| 13 | 13 | // error |
| 14 | // backend=stage2 | |
| 15 | // target=native | |
| 16 | 14 | // |
| 17 | 15 | // :3:6: error: invalid left-hand side to assignment |
| 18 | 16 | // :7:7: error: invalid left-hand side to assignment |
test/cases/compile_errors/invalid_bit_pointer.zig-2| ... | ... | @@ -6,8 +6,6 @@ comptime { |
| 6 | 6 | } |
| 7 | 7 | |
| 8 | 8 | // error |
| 9 | // backend=stage2 | |
| 10 | // target=native | |
| 11 | 9 | // |
| 12 | 10 | // :2:18: error: packed type 'u8' at bit offset 32 starts 0 bits after the end of a 4 byte host integer |
| 13 | 11 | // :5:18: error: packed type 'u8' at bit offset 25 ends 1 bits after the end of a 4 byte host integer |
test/cases/compile_errors/invalid_break_expression.zig-2| ... | ... | @@ -3,7 +3,5 @@ export fn f() void { |
| 3 | 3 | } |
| 4 | 4 | |
| 5 | 5 | // error |
| 6 | // backend=stage2 | |
| 7 | // target=native | |
| 8 | 6 | // |
| 9 | 7 | // :2:5: error: break expression outside loop |
test/cases/compile_errors/invalid_builtin_fn.zig-2| ... | ... | @@ -4,7 +4,5 @@ export fn entry() void { |
| 4 | 4 | } |
| 5 | 5 | |
| 6 | 6 | // error |
| 7 | // backend=stage2 | |
| 8 | // target=native | |
| 9 | 7 | // |
| 10 | 8 | // :1:8: error: invalid builtin function: '@bogus' |
test/cases/compile_errors/invalid_capture_type.zig-2| ... | ... | @@ -17,8 +17,6 @@ export fn f5() void { |
| 17 | 17 | } |
| 18 | 18 | |
| 19 | 19 | // error |
| 20 | // backend=stage2 | |
| 21 | // target=native | |
| 22 | 20 | // |
| 23 | 21 | // :2:9: error: expected optional type, found 'bool' |
| 24 | 22 | // :7:9: error: expected optional type, found 'usize' |
test/cases/compile_errors/invalid_cast_from_integral_type_to_enum.zig-2| ... | ... | @@ -11,8 +11,6 @@ fn foo(x: usize) void { |
| 11 | 11 | } |
| 12 | 12 | |
| 13 | 13 | // error |
| 14 | // backend=stage2 | |
| 15 | // target=native | |
| 16 | 14 | // |
| 17 | 15 | // :9:10: error: expected type 'usize', found 'tmp.E' |
| 18 | 16 | // :1:11: note: enum declared here |
test/cases/compile_errors/invalid_coercion_in_aggregate_literal.zig-2| ... | ... | @@ -14,8 +14,6 @@ export fn invalidStructField() u8 { |
| 14 | 14 | } |
| 15 | 15 | |
| 16 | 16 | // error |
| 17 | // backend=stage2 | |
| 18 | // target=native | |
| 19 | 17 | // |
| 20 | 18 | // :2:41: error: type 'u8' cannot represent integer value '256' |
| 21 | 19 | // :7:49: error: type 'u8' cannot represent integer value '256' |
test/cases/compile_errors/invalid_coercion_in_labeled_break.zig-2| ... | ... | @@ -6,7 +6,5 @@ export fn invalidBreak() u8 { |
| 6 | 6 | } |
| 7 | 7 | |
| 8 | 8 | // error |
| 9 | // backend=stage2 | |
| 10 | // target=native | |
| 11 | 9 | // |
| 12 | 10 | // :3:22: error: type 'u8' cannot represent integer value '256' |
test/cases/compile_errors/invalid_compare_string.zig-2| ... | ... | @@ -27,8 +27,6 @@ comptime { |
| 27 | 27 | } |
| 28 | 28 | |
| 29 | 29 | // error |
| 30 | // backend=stage2 | |
| 31 | // target=native | |
| 32 | 30 | // |
| 33 | 31 | // :3:11: error: cannot compare strings with != |
| 34 | 32 | // :7:11: error: cannot compare strings with == |
test/cases/compile_errors/invalid_comparison_for_function_pointers.zig-2| ... | ... | @@ -6,7 +6,5 @@ export fn entry() usize { |
| 6 | 6 | } |
| 7 | 7 | |
| 8 | 8 | // error |
| 9 | // backend=stage2 | |
| 10 | // target=native | |
| 11 | 9 | // |
| 12 | 10 | // :2:21: error: operator > not allowed for type 'fn () void' |
test/cases/compile_errors/invalid_comptime_fields.zig-2| ... | ... | @@ -12,8 +12,6 @@ const X = extern struct { |
| 12 | 12 | }; |
| 13 | 13 | |
| 14 | 14 | // error |
| 15 | // backend=stage2 | |
| 16 | // target=native | |
| 17 | 15 | // |
| 18 | 16 | // :2:5: error: union fields cannot be marked comptime |
| 19 | 17 | // :5:5: error: enum fields cannot be marked comptime |
test/cases/compile_errors/invalid_continue_expression.zig-2| ... | ... | @@ -3,7 +3,5 @@ export fn f() void { |
| 3 | 3 | } |
| 4 | 4 | |
| 5 | 5 | // error |
| 6 | // backend=stage2 | |
| 7 | // target=native | |
| 8 | 6 | // |
| 9 | 7 | // :2:5: error: continue expression outside loop |
test/cases/compile_errors/invalid_decltest.zig-2| ... | ... | @@ -6,8 +6,6 @@ export fn foo() void { |
| 6 | 6 | } |
| 7 | 7 | |
| 8 | 8 | // error |
| 9 | // backend=stage2 | |
| 10 | // target=native | |
| 11 | 9 | // |
| 12 | 10 | // :4:14: error: cannot test a local constant |
| 13 | 11 | // :2:11: note: local constant declared here |
test/cases/compile_errors/invalid_dependency_on_struct_size.zig-2| ... | ... | @@ -12,7 +12,5 @@ comptime { |
| 12 | 12 | } |
| 13 | 13 | |
| 14 | 14 | // error |
| 15 | // backend=stage2 | |
| 16 | // target=native | |
| 17 | 15 | // |
| 18 | 16 | // :6:21: error: struct layout depends on it having runtime bits |
test/cases/compile_errors/invalid_deref_on_switch_target.zig-2| ... | ... | @@ -11,8 +11,6 @@ const Tile = enum { |
| 11 | 11 | }; |
| 12 | 12 | |
| 13 | 13 | // error |
| 14 | // backend=stage2 | |
| 15 | // target=native | |
| 16 | 14 | // |
| 17 | 15 | // :3:17: error: cannot dereference non-pointer type 'tmp.Tile' |
| 18 | 16 | // :8:14: note: enum declared here |
test/cases/compile_errors/invalid_destructure_astgen.zig-2| ... | ... | @@ -13,8 +13,6 @@ export fn bar() void { |
| 13 | 13 | } |
| 14 | 14 | |
| 15 | 15 | // error |
| 16 | // backend=stage2 | |
| 17 | // target=native | |
| 18 | 16 | // |
| 19 | 17 | // :2:25: error: expected 2 elements for destructure, found 3 |
| 20 | 18 | // :2:22: note: result destructured here |
test/cases/compile_errors/invalid_destructure_error_union.zig-2| ... | ... | @@ -6,8 +6,6 @@ pub export fn entry() void { |
| 6 | 6 | } |
| 7 | 7 | |
| 8 | 8 | // error |
| 9 | // backend=stage2 | |
| 10 | // target=native | |
| 11 | 9 | // |
| 12 | 10 | // :3:28: error: type 'anyerror!u32' cannot be destructured |
| 13 | 11 | // :3:26: note: result destructured here |
test/cases/compile_errors/invalid_destructure_sema.zig-2| ... | ... | @@ -14,8 +14,6 @@ export fn bar() void { |
| 14 | 14 | } |
| 15 | 15 | |
| 16 | 16 | // error |
| 17 | // backend=stage2 | |
| 18 | // target=native | |
| 19 | 17 | // |
| 20 | 18 | // :2:24: error: type 'comptime_int' cannot be destructured |
| 21 | 19 | // :2:22: note: result destructured here |
test/cases/compile_errors/invalid_duplicate_test_decl_name.zig-2| ... | ... | @@ -2,8 +2,6 @@ test "thingy" {} |
| 2 | 2 | test "thingy" {} |
| 3 | 3 | |
| 4 | 4 | // error |
| 5 | // backend=stage2 | |
| 6 | // target=native | |
| 7 | 5 | // is_test=true |
| 8 | 6 | // |
| 9 | 7 | // :1:6: error: duplicate test name 'thingy' |
test/cases/compile_errors/invalid_empty_unicode_escape.zig-2| ... | ... | @@ -3,7 +3,5 @@ export fn entry() void { |
| 3 | 3 | } |
| 4 | 4 | |
| 5 | 5 | // error |
| 6 | // backend=stage2 | |
| 7 | // target=native | |
| 8 | 6 | // |
| 9 | 7 | // :2:19: error: empty unicode escape sequence |
test/cases/compile_errors/invalid_error_capture_discard.zig-2| ... | ... | @@ -19,8 +19,6 @@ export fn d() void { |
| 19 | 19 | } |
| 20 | 20 | |
| 21 | 21 | // error |
| 22 | // backend=stage2 | |
| 23 | // target=native | |
| 24 | 22 | // |
| 25 | 23 | // :2:15: error: discard of error capture; omit it instead |
| 26 | 24 | // :3:9: error: use of undeclared identifier '_' |
test/cases/compile_errors/invalid_error_union_payload_type.zig-2| ... | ... | @@ -12,8 +12,6 @@ comptime { |
| 12 | 12 | } |
| 13 | 13 | |
| 14 | 14 | // error |
| 15 | // backend=stage2 | |
| 16 | // target=native | |
| 17 | 15 | // |
| 18 | 16 | // :2:18: error: error union with payload of opaque type 'anyopaque' not allowed |
| 19 | 17 | // :5:18: error: error union with payload of error set type 'anyerror' not allowed |
test/cases/compile_errors/invalid_exponent_in_float_literal-1.zig-2| ... | ... | @@ -4,7 +4,5 @@ fn main() void { |
| 4 | 4 | } |
| 5 | 5 | |
| 6 | 6 | // error |
| 7 | // backend=stage2 | |
| 8 | // target=native | |
| 9 | 7 | // |
| 10 | 8 | // :2:28: error: invalid digit 'a' in exponent |
test/cases/compile_errors/invalid_exponent_in_float_literal-2.zig-2| ... | ... | @@ -4,7 +4,5 @@ fn main() void { |
| 4 | 4 | } |
| 5 | 5 | |
| 6 | 6 | // error |
| 7 | // backend=stage2 | |
| 8 | // target=native | |
| 9 | 7 | // |
| 10 | 8 | // :2:29: error: invalid digit 'F' in exponent |
test/cases/compile_errors/invalid_field_access_in_comptime.zig-2| ... | ... | @@ -4,7 +4,5 @@ comptime { |
| 4 | 4 | } |
| 5 | 5 | |
| 6 | 6 | // error |
| 7 | // backend=stage2 | |
| 8 | // target=native | |
| 9 | 7 | // |
| 10 | 8 | // :2:13: error: use of undeclared identifier 'doesnt_exist' |
test/cases/compile_errors/invalid_field_in_struct_value_expression.zig-2| ... | ... | @@ -29,8 +29,6 @@ pub export fn entry1() void { |
| 29 | 29 | } |
| 30 | 30 | |
| 31 | 31 | // error |
| 32 | // backend=stage2 | |
| 33 | // target=native | |
| 34 | 32 | // |
| 35 | 33 | // :10:10: error: no field named 'foo' in struct 'tmp.A' |
| 36 | 34 | // :1:11: note: struct declared here |
test/cases/compile_errors/invalid_float_casts.zig-2| ... | ... | @@ -20,8 +20,6 @@ export fn qux() void { |
| 20 | 20 | } |
| 21 | 21 | |
| 22 | 22 | // error |
| 23 | // backend=stage2 | |
| 24 | // target=native | |
| 25 | 23 | // |
| 26 | 24 | // :4:40: error: unable to cast runtime value to 'comptime_float' |
| 27 | 25 | // :9:18: error: expected integer type, found 'f32' |
test/cases/compile_errors/invalid_float_literal.zig-2| ... | ... | @@ -7,7 +7,5 @@ pub fn main() void { |
| 7 | 7 | } |
| 8 | 8 | |
| 9 | 9 | // error |
| 10 | // backend=stage2 | |
| 11 | // target=native | |
| 12 | 10 | // |
| 13 | 11 | // :5:29: error: expected expression, found '.' |
test/cases/compile_errors/invalid_function_types.zig-2| ... | ... | @@ -15,8 +15,6 @@ comptime { |
| 15 | 15 | } |
| 16 | 16 | |
| 17 | 17 | // error |
| 18 | // backend=stage2 | |
| 19 | // target=native | |
| 20 | 18 | // |
| 21 | 19 | // :2:12: error: function type cannot have a name |
| 22 | 20 | // :5:21: error: function type cannot have an alignment |
test/cases/compile_errors/invalid_identifiers.zig-2| ... | ... | @@ -18,8 +18,6 @@ comptime { |
| 18 | 18 | } |
| 19 | 19 | |
| 20 | 20 | // error |
| 21 | // backend=stage2 | |
| 22 | // target=native | |
| 23 | 21 | // |
| 24 | 22 | // :1:8: error: library name cannot be empty |
| 25 | 23 | // :2:8: error: library name cannot be empty |
test/cases/compile_errors/invalid_if_expr_result_location_coercion.zig-2| ... | ... | @@ -23,8 +23,6 @@ export fn invalidComptimeElse() u0 { |
| 23 | 23 | } |
| 24 | 24 | |
| 25 | 25 | // error |
| 26 | // backend=stage2 | |
| 27 | // target=native | |
| 28 | 26 | // |
| 29 | 27 | // :3:34: error: type 'u8' cannot represent integer value '256' |
| 30 | 28 | // :9:34: error: type 'u8' cannot represent integer value '256' |
test/cases/compile_errors/invalid_inline_else_type.zig-2| ... | ... | @@ -22,8 +22,6 @@ pub export fn entry3() void { |
| 22 | 22 | } |
| 23 | 23 | |
| 24 | 24 | // error |
| 25 | // backend=stage2 | |
| 26 | // target=native | |
| 27 | 25 | // |
| 28 | 26 | // :5:21: error: cannot enumerate values of type 'anyerror' for 'inline else' |
| 29 | 27 | // :13:21: error: cannot enumerate values of type 'tmp.E' for 'inline else' |
test/cases/compile_errors/invalid_int_casts.zig-2| ... | ... | @@ -20,8 +20,6 @@ export fn qux() void { |
| 20 | 20 | } |
| 21 | 21 | |
| 22 | 22 | // error |
| 23 | // backend=stage2 | |
| 24 | // target=native | |
| 25 | 23 | // |
| 26 | 24 | // :4:36: error: unable to cast runtime value to 'comptime_int' |
| 27 | 25 | // :9:18: error: expected float type, found 'u32' |
test/cases/compile_errors/invalid_legacy_unicode_escape.zig-2| ... | ... | @@ -3,7 +3,5 @@ export fn entry() void { |
| 3 | 3 | } |
| 4 | 4 | |
| 5 | 5 | // error |
| 6 | // backend=stage2 | |
| 7 | // target=native | |
| 8 | 6 | // |
| 9 | 7 | // :2:17: error: invalid escape character: 'U' |
test/cases/compile_errors/invalid_member_of_builtin_enum.zig-2| ... | ... | @@ -5,8 +5,6 @@ export fn entry() void { |
| 5 | 5 | } |
| 6 | 6 | |
| 7 | 7 | // error |
| 8 | // backend=stage2 | |
| 9 | // target=native | |
| 10 | 8 | // |
| 11 | 9 | // :3:38: error: enum 'builtin.OptimizeMode' has no member named 'x86' |
| 12 | 10 | // : note: enum declared here |
test/cases/compile_errors/invalid_multiple_dereferences.zig-2| ... | ... | @@ -13,8 +13,6 @@ pub const Box = struct { |
| 13 | 13 | }; |
| 14 | 14 | |
| 15 | 15 | // error |
| 16 | // backend=stage2 | |
| 17 | // target=native | |
| 18 | 16 | // |
| 19 | 17 | // :4:8: error: cannot dereference non-pointer type 'tmp.Box' |
| 20 | 18 | // :11:17: note: struct declared here |
test/cases/compile_errors/invalid_non-exhaustive_enum_to_union.zig-2| ... | ... | @@ -19,8 +19,6 @@ export fn bar() void { |
| 19 | 19 | } |
| 20 | 20 | |
| 21 | 21 | // error |
| 22 | // backend=stage2 | |
| 23 | // target=native | |
| 24 | 22 | // |
| 25 | 23 | // :12:16: error: runtime coercion to union 'tmp.U' from non-exhaustive enum |
| 26 | 24 | // :1:11: note: enum declared here |
test/cases/compile_errors/invalid_number_literals.zig-2| ... | ... | @@ -18,8 +18,6 @@ comptime { |
| 18 | 18 | } |
| 19 | 19 | |
| 20 | 20 | // error |
| 21 | // backend=stage2 | |
| 22 | // target=native | |
| 23 | 21 | // |
| 24 | 22 | // :2:11: error: unexpected period after exponent |
| 25 | 23 | // :5:11: error: unexpected period after exponent |
test/cases/compile_errors/invalid_optional_payload_type.zig-2| ... | ... | @@ -6,8 +6,6 @@ comptime { |
| 6 | 6 | } |
| 7 | 7 | |
| 8 | 8 | // error |
| 9 | // backend=stage2 | |
| 10 | // target=native | |
| 11 | 9 | // |
| 12 | 10 | // :2:10: error: opaque type 'anyopaque' cannot be optional |
| 13 | 11 | // :5:10: error: type '@TypeOf(null)' cannot be optional |
test/cases/compile_errors/invalid_optional_type_in_extern_struct.zig-2| ... | ... | @@ -6,8 +6,6 @@ export fn testf(fluff: *stroo) void { |
| 6 | 6 | } |
| 7 | 7 | |
| 8 | 8 | // error |
| 9 | // backend=stage2 | |
| 10 | // target=native | |
| 11 | 9 | // |
| 12 | 10 | // :2:10: error: extern structs cannot contain fields of type '?[*c]u8' |
| 13 | 11 | // :2:10: note: only pointer like optionals are extern compatible |
test/cases/compile_errors/invalid_peer_type_resolution.zig-2| ... | ... | @@ -24,8 +24,6 @@ export fn incompatiblePointers4() void { |
| 24 | 24 | } |
| 25 | 25 | |
| 26 | 26 | // error |
| 27 | // backend=stage2 | |
| 28 | // target=native | |
| 29 | 27 | // |
| 30 | 28 | // :5:9: error: incompatible types: '?@Vector(10, i32)' and '@Vector(11, i32)' |
| 31 | 29 | // :5:17: note: type '?@Vector(10, i32)' here |
test/cases/compile_errors/invalid_pointer_arithmetic.zig-2| ... | ... | @@ -38,8 +38,6 @@ comptime { |
| 38 | 38 | } |
| 39 | 39 | |
| 40 | 40 | // error |
| 41 | // backend=stage2 | |
| 42 | // target=native | |
| 43 | 41 | // |
| 44 | 42 | // :2:11: error: invalid pointer-integer arithmetic operator |
| 45 | 43 | // :2:11: note: pointer-integer arithmetic only supports addition and subtraction |
test/cases/compile_errors/invalid_pointer_keeps_address_space_when_taking_address_of_dereference.zig-1| ... | ... | @@ -7,7 +7,6 @@ pub fn main() void { |
| 7 | 7 | |
| 8 | 8 | // error |
| 9 | 9 | // output_mode=Exe |
| 10 | // backend=stage2,llvm | |
| 11 | 10 | // target=x86_64-linux,x86_64-macos |
| 12 | 11 | // |
| 13 | 12 | // :2:12: error: expected type '*i32', found '*addrspace(.gs) i32' |
test/cases/compile_errors/invalid_pointer_syntax.zig-2| ... | ... | @@ -3,7 +3,5 @@ export fn foo() void { |
| 3 | 3 | } |
| 4 | 4 | |
| 5 | 5 | // error |
| 6 | // backend=stage2 | |
| 7 | // target=native | |
| 8 | 6 | // |
| 9 | 7 | // :2:16: error: expected type expression, found ':' |
test/cases/compile_errors/invalid_shift_amount_error.zig-2| ... | ... | @@ -7,7 +7,5 @@ export fn entry() u16 { |
| 7 | 7 | } |
| 8 | 8 | |
| 9 | 9 | // error |
| 10 | // backend=stage2 | |
| 11 | // target=native | |
| 12 | 10 | // |
| 13 | 11 | // :3:17: error: type 'u3' cannot represent integer value '8' |
test/cases/compile_errors/invalid_store_to_comptime_field.zig-2| ... | ... | @@ -70,8 +70,6 @@ pub export fn entry8() void { |
| 70 | 70 | } |
| 71 | 71 | |
| 72 | 72 | // error |
| 73 | // target=native | |
| 74 | // backend=stage2 | |
| 75 | 73 | // |
| 76 | 74 | // :6:9: error: value stored in comptime field does not match the default value of the field |
| 77 | 75 | // :14:9: error: value stored in comptime field does not match the default value of the field |
test/cases/compile_errors/invalid_struct_field.zig-2| ... | ... | @@ -20,8 +20,6 @@ export fn e() void { |
| 20 | 20 | } |
| 21 | 21 | |
| 22 | 22 | // error |
| 23 | // backend=stage2 | |
| 24 | // target=native | |
| 25 | 23 | // |
| 26 | 24 | // :4:7: error: no field named 'foo' in struct 'tmp.A' |
| 27 | 25 | // :1:11: note: struct declared here |
test/cases/compile_errors/invalid_switch_expr_result_location_coercion.zig-2| ... | ... | @@ -37,8 +37,6 @@ export fn invalidNonExhaustiveProng(enum_value: Enum) u8 { |
| 37 | 37 | } |
| 38 | 38 | |
| 39 | 39 | // error |
| 40 | // backend=stage2 | |
| 41 | // target=native | |
| 42 | 40 | // |
| 43 | 41 | // :5:19: error: type 'u8' cannot represent integer value '256' |
| 44 | 42 | // :15:20: error: type 'u8' cannot represent integer value '256' |
test/cases/compile_errors/invalid_tag_capture.zig-2| ... | ... | @@ -8,8 +8,6 @@ pub export fn entry() void { |
| 8 | 8 | } |
| 9 | 9 | |
| 10 | 10 | // error |
| 11 | // backend=stage2 | |
| 12 | // target=native | |
| 13 | 11 | // |
| 14 | 12 | // :5:33: error: cannot capture tag of non-union type 'tmp.E' |
| 15 | 13 | // :1:11: note: enum declared here |
test/cases/compile_errors/invalid_tail_call.zig-1| ... | ... | @@ -7,6 +7,5 @@ pub export fn entry() void { |
| 7 | 7 | |
| 8 | 8 | // error |
| 9 | 9 | // backend=llvm |
| 10 | // target=native | |
| 11 | 10 | // |
| 12 | 11 | // :5:5: error: unable to perform tail call: type of function being called 'fn (usize) void' does not match type of calling function 'fn () callconv(.c) void' |
test/cases/compile_errors/invalid_type.zig-2| ... | ... | @@ -4,7 +4,5 @@ export fn entry() void { |
| 4 | 4 | } |
| 5 | 5 | |
| 6 | 6 | // error |
| 7 | // backend=stage2 | |
| 8 | // target=native | |
| 9 | 7 | // |
| 10 | 8 | // :1:8: error: use of undeclared identifier 'bogus' |
test/cases/compile_errors/invalid_type_in_builtin_extern.zig-2| ... | ... | @@ -8,8 +8,6 @@ pub export fn entry2() void { |
| 8 | 8 | } |
| 9 | 9 | |
| 10 | 10 | // error |
| 11 | // backend=stage2 | |
| 12 | // target=native | |
| 13 | 11 | // |
| 14 | 12 | // :1:19: error: extern symbol cannot have type '*comptime_int' |
| 15 | 13 | // :1:19: note: pointer to comptime-only type 'comptime_int' |
test/cases/compile_errors/invalid_type_used_in_array_type.zig-2| ... | ... | @@ -8,7 +8,5 @@ export fn entry() void { |
| 8 | 8 | } |
| 9 | 9 | |
| 10 | 10 | // error |
| 11 | // backend=stage2 | |
| 12 | // target=native | |
| 13 | 11 | // |
| 14 | 12 | // :2:12: error: use of undeclared identifier 'SomeNonexistentType' |
test/cases/compile_errors/invalid_underscore_placement_in_float_literal-1.zig-2| ... | ... | @@ -4,7 +4,5 @@ fn main() void { |
| 4 | 4 | } |
| 5 | 5 | |
| 6 | 6 | // error |
| 7 | // backend=stage2 | |
| 8 | // target=native | |
| 9 | 7 | // |
| 10 | 8 | // :2:23: error: expected digit before digit separator |
test/cases/compile_errors/invalid_underscore_placement_in_float_literal-10.zig-2| ... | ... | @@ -4,7 +4,5 @@ fn main() void { |
| 4 | 4 | } |
| 5 | 5 | |
| 6 | 6 | // error |
| 7 | // backend=stage2 | |
| 8 | // target=native | |
| 9 | 7 | // |
| 10 | 8 | // :2:25: error: repeated digit separator |
test/cases/compile_errors/invalid_underscore_placement_in_float_literal-11.zig-2| ... | ... | @@ -4,7 +4,5 @@ fn main() void { |
| 4 | 4 | } |
| 5 | 5 | |
| 6 | 6 | // error |
| 7 | // backend=stage2 | |
| 8 | // target=native | |
| 9 | 7 | // |
| 10 | 8 | // :2:28: error: repeated digit separator |
test/cases/compile_errors/invalid_underscore_placement_in_float_literal-12.zig-2| ... | ... | @@ -4,7 +4,5 @@ fn main() void { |
| 4 | 4 | } |
| 5 | 5 | |
| 6 | 6 | // error |
| 7 | // backend=stage2 | |
| 8 | // target=native | |
| 9 | 7 | // |
| 10 | 8 | // :2:23: error: invalid digit 'x' for decimal base |
test/cases/compile_errors/invalid_underscore_placement_in_float_literal-13.zig-2| ... | ... | @@ -4,7 +4,5 @@ fn main() void { |
| 4 | 4 | } |
| 5 | 5 | |
| 6 | 6 | // error |
| 7 | // backend=stage2 | |
| 8 | // target=native | |
| 9 | 7 | // |
| 10 | 8 | // :2:23: error: expected digit before digit separator |
test/cases/compile_errors/invalid_underscore_placement_in_float_literal-14.zig-2| ... | ... | @@ -4,7 +4,5 @@ fn main() void { |
| 4 | 4 | } |
| 5 | 5 | |
| 6 | 6 | // error |
| 7 | // backend=stage2 | |
| 8 | // target=native | |
| 9 | 7 | // |
| 10 | 8 | // :2:27: error: expected digit before exponent |
test/cases/compile_errors/invalid_underscore_placement_in_float_literal-2.zig-2| ... | ... | @@ -4,7 +4,5 @@ fn main() void { |
| 4 | 4 | } |
| 5 | 5 | |
| 6 | 6 | // error |
| 7 | // backend=stage2 | |
| 8 | // target=native | |
| 9 | 7 | // |
| 10 | 8 | // :2:23: error: expected digit before '.' |
test/cases/compile_errors/invalid_underscore_placement_in_float_literal-3.zig-2| ... | ... | @@ -4,7 +4,5 @@ fn main() void { |
| 4 | 4 | } |
| 5 | 5 | |
| 6 | 6 | // error |
| 7 | // backend=stage2 | |
| 8 | // target=native | |
| 9 | 7 | // |
| 10 | 8 | // :2:24: error: trailing digit separator |
test/cases/compile_errors/invalid_underscore_placement_in_float_literal-4.zig-2| ... | ... | @@ -4,7 +4,5 @@ fn main() void { |
| 4 | 4 | } |
| 5 | 5 | |
| 6 | 6 | // error |
| 7 | // backend=stage2 | |
| 8 | // target=native | |
| 9 | 7 | // |
| 10 | 8 | // :2:25: error: expected digit before digit separator |
test/cases/compile_errors/invalid_underscore_placement_in_float_literal-5.zig-2| ... | ... | @@ -4,7 +4,5 @@ fn main() void { |
| 4 | 4 | } |
| 5 | 5 | |
| 6 | 6 | // error |
| 7 | // backend=stage2 | |
| 8 | // target=native | |
| 9 | 7 | // |
| 10 | 8 | // :2:26: error: expected digit before digit separator |
test/cases/compile_errors/invalid_underscore_placement_in_float_literal-6.zig-2| ... | ... | @@ -4,7 +4,5 @@ fn main() void { |
| 4 | 4 | } |
| 5 | 5 | |
| 6 | 6 | // error |
| 7 | // backend=stage2 | |
| 8 | // target=native | |
| 9 | 7 | // |
| 10 | 8 | // :2:26: error: expected digit before digit separator |
test/cases/compile_errors/invalid_underscore_placement_in_float_literal-7.zig-2| ... | ... | @@ -4,7 +4,5 @@ fn main() void { |
| 4 | 4 | } |
| 5 | 5 | |
| 6 | 6 | // error |
| 7 | // backend=stage2 | |
| 8 | // target=native | |
| 9 | 7 | // |
| 10 | 8 | // :2:27: error: trailing digit separator |
test/cases/compile_errors/invalid_underscore_placement_in_float_literal-9.zig-2| ... | ... | @@ -4,7 +4,5 @@ fn main() void { |
| 4 | 4 | } |
| 5 | 5 | |
| 6 | 6 | // error |
| 7 | // backend=stage2 | |
| 8 | // target=native | |
| 9 | 7 | // |
| 10 | 8 | // :2:23: error: repeated digit separator |
test/cases/compile_errors/invalid_underscore_placement_in_int_literal-1.zig-2| ... | ... | @@ -4,7 +4,5 @@ fn main() void { |
| 4 | 4 | } |
| 5 | 5 | |
| 6 | 6 | // error |
| 7 | // backend=stage2 | |
| 8 | // target=native | |
| 9 | 7 | // |
| 10 | 8 | // :2:23: error: trailing digit separator |
test/cases/compile_errors/invalid_underscore_placement_in_int_literal-2.zig-2| ... | ... | @@ -4,7 +4,5 @@ fn main() void { |
| 4 | 4 | } |
| 5 | 5 | |
| 6 | 6 | // error |
| 7 | // backend=stage2 | |
| 8 | // target=native | |
| 9 | 7 | // |
| 10 | 8 | // :2:27: error: trailing digit separator |
test/cases/compile_errors/invalid_underscore_placement_in_int_literal-3.zig-2| ... | ... | @@ -4,7 +4,5 @@ fn main() void { |
| 4 | 4 | } |
| 5 | 5 | |
| 6 | 6 | // error |
| 7 | // backend=stage2 | |
| 8 | // target=native | |
| 9 | 7 | // |
| 10 | 8 | // :2:27: error: trailing digit separator |
test/cases/compile_errors/invalid_underscore_placement_in_int_literal-4.zig-2| ... | ... | @@ -4,7 +4,5 @@ fn main() void { |
| 4 | 4 | } |
| 5 | 5 | |
| 6 | 6 | // error |
| 7 | // backend=stage2 | |
| 8 | // target=native | |
| 9 | 7 | // |
| 10 | 8 | // :2:27: error: trailing digit separator |
test/cases/compile_errors/invalid_unicode_escape.zig-2| ... | ... | @@ -3,8 +3,6 @@ export fn entry() void { |
| 3 | 3 | } |
| 4 | 4 | |
| 5 | 5 | // error |
| 6 | // backend=stage2 | |
| 7 | // target=native | |
| 8 | 6 | // |
| 9 | 7 | // :2:21: error: expected hex digit or '}', found 'z' |
| 10 | 8 |
test/cases/compile_errors/issue_15572_break_on_inline_while.zig-1| ... | ... | @@ -14,7 +14,6 @@ pub fn main() void { |
| 14 | 14 | } |
| 15 | 15 | |
| 16 | 16 | // error |
| 17 | // backend=stage2 | |
| 18 | 17 | // target=x86_64-linux |
| 19 | 18 | // |
| 20 | 19 | // :9:28: error: incompatible types: 'builtin.Type.EnumField' and 'void' |
test/cases/compile_errors/issue_2032_compile_diagnostic_string_for_top_level_decl_type.zig-2| ... | ... | @@ -4,8 +4,6 @@ export fn entry() void { |
| 4 | 4 | } |
| 5 | 5 | |
| 6 | 6 | // error |
| 7 | // backend=stage2 | |
| 8 | // target=native | |
| 9 | 7 | // |
| 10 | 8 | // :2:29: error: expected type 'u32', found 'tmp' |
| 11 | 9 | // :1:1: note: struct declared here |
test/cases/compile_errors/issue_3818_bitcast_from_parray-slice_to_u16.zig-2| ... | ... | @@ -10,8 +10,6 @@ export fn foo2() void { |
| 10 | 10 | } |
| 11 | 11 | |
| 12 | 12 | // error |
| 13 | // backend=stage2 | |
| 14 | // target=native | |
| 15 | 13 | // |
| 16 | 14 | // :3:37: error: cannot @bitCast from '*[2]u8' |
| 17 | 15 | // :3:37: note: use @intFromPtr to cast to 'u16' |
test/cases/compile_errors/issue_4207_coerce_from_non-terminated-slice_to_terminated-pointer.zig-2| ... | ... | @@ -4,8 +4,6 @@ export fn foo() [*:0]const u8 { |
| 4 | 4 | } |
| 5 | 5 | |
| 6 | 6 | // error |
| 7 | // backend=stage2 | |
| 8 | // target=native | |
| 9 | 7 | // |
| 10 | 8 | // :3:18: error: expected type '[*:0]const u8', found '*[64]u8' |
| 11 | 9 | // :3:18: note: destination pointer requires '0' sentinel |
test/cases/compile_errors/issue_5221_invalid_struct_init_type_referenced_by_typeInfo_and_passed_into_function.zig-2| ... | ... | @@ -11,8 +11,6 @@ export fn foo() void { |
| 11 | 11 | } |
| 12 | 12 | |
| 13 | 13 | // error |
| 14 | // backend=stage2 | |
| 15 | // target=native | |
| 16 | 14 | // |
| 17 | 15 | // :7:28: error: expected type '[]u8', found '*const [3:0]u8' |
| 18 | 16 | // :7:28: note: cast discards const qualifier |
test/cases/compile_errors/issue_5618_coercion_of_optional_anyopaque_to_anyopaque_must_fail.zig-2| ... | ... | @@ -5,8 +5,6 @@ export fn foo() void { |
| 5 | 5 | } |
| 6 | 6 | |
| 7 | 7 | // error |
| 8 | // backend=stage2 | |
| 9 | // target=native | |
| 10 | 8 | // |
| 11 | 9 | // :4:13: error: expected type '*anyopaque', found '?*anyopaque' |
| 12 | 10 | // :4:13: note: cannot convert optional to payload type |
test/cases/compile_errors/issue_9346_return_outside_of_function_scope.zig-2| ... | ... | @@ -1,7 +1,5 @@ |
| 1 | 1 | pub const empty = return 1; |
| 2 | 2 | |
| 3 | 3 | // error |
| 4 | // backend=stage2 | |
| 5 | // target=native | |
| 6 | 4 | // |
| 7 | 5 | // :1:19: error: 'return' outside function scope |
test/cases/compile_errors/labeled_break_not_found.zig-2| ... | ... | @@ -7,7 +7,5 @@ export fn entry() void { |
| 7 | 7 | } |
| 8 | 8 | |
| 9 | 9 | // error |
| 10 | // backend=stage2 | |
| 11 | // target=native | |
| 12 | 10 | // |
| 13 | 11 | // :4:20: error: label not found: 'outer' |
test/cases/compile_errors/labeled_continue_not_found.zig-2| ... | ... | @@ -8,7 +8,5 @@ export fn entry() void { |
| 8 | 8 | } |
| 9 | 9 | |
| 10 | 10 | // error |
| 11 | // backend=stage2 | |
| 12 | // target=native | |
| 13 | 11 | // |
| 14 | 12 | // :5:23: error: label not found: 'outer' |
test/cases/compile_errors/leading_zero_in_integer.zig-2| ... | ... | @@ -16,8 +16,6 @@ export fn entry4() void { |
| 16 | 16 | } |
| 17 | 17 | |
| 18 | 18 | // error |
| 19 | // backend=stage2 | |
| 20 | // target=native | |
| 21 | 19 | // |
| 22 | 20 | // :2:15: error: primitive integer type 'u000123' has leading zero |
| 23 | 21 | // :8:12: error: primitive integer type 'i01' has leading zero |
test/cases/compile_errors/len_access_on_array_many_ptr.zig-2| ... | ... | @@ -4,7 +4,5 @@ export fn foo() void { |
| 4 | 4 | } |
| 5 | 5 | |
| 6 | 6 | // error |
| 7 | // backend=stage2 | |
| 8 | // target=native | |
| 9 | 7 | // |
| 10 | 8 | // :3:10: error: type '[*][5]u8' does not support field access |
test/cases/compile_errors/load_too_many_bytes_from_comptime_reinterpreted_pointer.zig-2| ... | ... | @@ -7,7 +7,5 @@ export fn entry() void { |
| 7 | 7 | } |
| 8 | 8 | |
| 9 | 9 | // error |
| 10 | // backend=stage2 | |
| 11 | // target=native | |
| 12 | 10 | // |
| 13 | 11 | // :5:28: error: dereference of '*const i64' exceeds bounds of containing decl of type 'f32' |
test/cases/compile_errors/load_vector_pointer_with_unknown_runtime_index.zig-2| ... | ... | @@ -11,7 +11,5 @@ fn loadv(ptr: anytype) i31 { |
| 11 | 11 | } |
| 12 | 12 | |
| 13 | 13 | // error |
| 14 | // backend=stage2 | |
| 15 | // target=native | |
| 16 | 14 | // |
| 17 | 15 | // :10:15: error: unable to determine vector element index of type '*align(16:0:4:?) i31' |
test/cases/compile_errors/local_shadows_global_that_occurs_later.zig-2| ... | ... | @@ -5,8 +5,6 @@ pub fn main() void { |
| 5 | 5 | fn foo() void {} |
| 6 | 6 | |
| 7 | 7 | // error |
| 8 | // backend=stage2 | |
| 9 | // target=native | |
| 10 | 8 | // |
| 11 | 9 | // :2:9: error: local variable shadows declaration of 'foo' |
| 12 | 10 | // :5:1: note: declared here |
test/cases/compile_errors/local_variable_redeclaration.zig-2| ... | ... | @@ -4,8 +4,6 @@ export fn f() void { |
| 4 | 4 | } |
| 5 | 5 | |
| 6 | 6 | // error |
| 7 | // backend=stage2 | |
| 8 | // target=native | |
| 9 | 7 | // |
| 10 | 8 | // :3:9: error: redeclaration of local constant 'a' |
| 11 | 9 | // :2:11: note: previous declaration here |
test/cases/compile_errors/local_variable_redeclares_parameter.zig-2| ... | ... | @@ -6,8 +6,6 @@ export fn entry() void { |
| 6 | 6 | } |
| 7 | 7 | |
| 8 | 8 | // error |
| 9 | // backend=stage2 | |
| 10 | // target=native | |
| 11 | 9 | // |
| 12 | 10 | // :2:11: error: local constant 'a' shadows function parameter from outer scope |
| 13 | 11 | // :1:6: note: previous declaration here |
test/cases/compile_errors/local_variable_shadowing_global.zig-2| ... | ... | @@ -7,8 +7,6 @@ export fn entry() void { |
| 7 | 7 | } |
| 8 | 8 | |
| 9 | 9 | // error |
| 10 | // backend=stage2 | |
| 11 | // target=native | |
| 12 | 10 | // |
| 13 | 11 | // :5:9: error: local variable shadows declaration of 'Bar' |
| 14 | 12 | // :2:1: note: declared here |
test/cases/compile_errors/locally_shadowing_a_primitive_type.zig-2| ... | ... | @@ -5,8 +5,6 @@ export fn foo() void { |
| 5 | 5 | } |
| 6 | 6 | |
| 7 | 7 | // error |
| 8 | // backend=stage2 | |
| 9 | // target=native | |
| 10 | 8 | // |
| 11 | 9 | // :2:11: error: name shadows primitive 'u8' |
| 12 | 10 | // :2:11: note: consider using @"u8" to disambiguate |
test/cases/compile_errors/main_function_with_bogus_args_type.zig-2| ... | ... | @@ -3,7 +3,5 @@ pub fn main(args: [][]bogus) !void { |
| 3 | 3 | } |
| 4 | 4 | |
| 5 | 5 | // error |
| 6 | // backend=stage2 | |
| 7 | // target=native | |
| 8 | 6 | // |
| 9 | 7 | // :1:23: error: use of undeclared identifier 'bogus' |
test/cases/compile_errors/main_missing_name.zig-2| ... | ... | @@ -1,8 +1,6 @@ |
| 1 | 1 | pub fn (main) void {} |
| 2 | 2 | |
| 3 | 3 | // error |
| 4 | // backend=stage2 | |
| 5 | // target=native | |
| 6 | 4 | // output_mode=Exe |
| 7 | 5 | // |
| 8 | 6 | // :1:5: error: missing function name |
test/cases/compile_errors/member_function_arg_mismatch.zig-2| ... | ... | @@ -8,8 +8,6 @@ pub export fn entry() void { |
| 8 | 8 | } |
| 9 | 9 | |
| 10 | 10 | // error |
| 11 | // backend=stage2 | |
| 12 | // target=native | |
| 13 | 11 | // |
| 14 | 12 | // :7:6: error: member function expected 2 argument(s), found 1 |
| 15 | 13 | // :3:5: note: function declared here |
test/cases/compile_errors/memset_no_length.zig-2| ... | ... | @@ -10,8 +10,6 @@ export fn bar() void { |
| 10 | 10 | } |
| 11 | 11 | |
| 12 | 12 | // error |
| 13 | // backend=stage2 | |
| 14 | // target=native | |
| 15 | 13 | // |
| 16 | 14 | // :4:5: error: unknown @memset length |
| 17 | 15 | // :4:13: note: destination type '[*]u8' provides no length |
test/cases/compile_errors/method_call_on_error_union.zig-2| ... | ... | @@ -14,8 +14,6 @@ export fn entry() void { |
| 14 | 14 | } |
| 15 | 15 | |
| 16 | 16 | // error |
| 17 | // backend=stage2 | |
| 18 | // target=native | |
| 19 | 17 | // |
| 20 | 18 | // :13:6: error: no field or member function named 'a' in '@typeInfo(@typeInfo(@TypeOf(tmp.X.init)).@"fn".return_type.?).error_union.error_set!tmp.X' |
| 21 | 19 | // :13:6: note: consider using 'try', 'catch', or 'if' |
test/cases/compile_errors/method_call_with_first_arg_type_primitive.zig-2| ... | ... | @@ -15,8 +15,6 @@ export fn f() void { |
| 15 | 15 | } |
| 16 | 16 | |
| 17 | 17 | // error |
| 18 | // backend=stage2 | |
| 19 | // target=native | |
| 20 | 18 | // |
| 21 | 19 | // :14:9: error: no field or member function named 'init' in 'tmp.Foo' |
| 22 | 20 | // :1:13: note: struct declared here |
test/cases/compile_errors/method_call_with_first_arg_type_wrong_container.zig-2| ... | ... | @@ -24,8 +24,6 @@ export fn foo() void { |
| 24 | 24 | } |
| 25 | 25 | |
| 26 | 26 | // error |
| 27 | // backend=stage2 | |
| 28 | // target=native | |
| 29 | 27 | // |
| 30 | 28 | // :23:6: error: no field or member function named 'init' in 'tmp.List' |
| 31 | 29 | // :1:18: note: struct declared here |
test/cases/compile_errors/minmax_missing_args.zig-2| ... | ... | @@ -2,8 +2,6 @@ comptime { _ = @min(1); } |
| 2 | 2 | comptime { _ = @max(1); } |
| 3 | 3 | |
| 4 | 4 | // error |
| 5 | // backend=stage2 | |
| 6 | // target=native | |
| 7 | 5 | // |
| 8 | 6 | // :1:16: error: expected at least 2 arguments, found 1 |
| 9 | 7 | // :2:16: error: expected at least 2 arguments, found 1 |
test/cases/compile_errors/minmax_nonnumeric_operand.zig-2| ... | ... | @@ -19,8 +19,6 @@ const Enum = enum { foo }; |
| 19 | 19 | const Union = union { foo: void }; |
| 20 | 20 | |
| 21 | 21 | // error |
| 22 | // backend=stage2 | |
| 23 | // target=native | |
| 24 | 22 | // |
| 25 | 23 | // :2:24: error: expected number, found 'type' |
| 26 | 24 | // :3:24: error: expected number, found 'void' |
test/cases/compile_errors/missing_boolean_switch_value.zig-2| ... | ... | @@ -12,8 +12,6 @@ comptime { |
| 12 | 12 | } |
| 13 | 13 | |
| 14 | 14 | // error |
| 15 | // backend=stage2 | |
| 16 | // target=native | |
| 17 | 15 | // |
| 18 | 16 | // :2:15: error: switch must handle all possibilities |
| 19 | 17 | // :8:15: error: switch must handle all possibilities |
test/cases/compile_errors/missing_builtin_arg_in_initializer.zig-2| ... | ... | @@ -9,8 +9,6 @@ comptime { |
| 9 | 9 | } |
| 10 | 10 | |
| 11 | 11 | // error |
| 12 | // backend=stage2 | |
| 13 | // target=native | |
| 14 | 12 | // |
| 15 | 13 | // :2:15: error: expected 2 arguments, found 0 |
| 16 | 14 | // :5:15: error: expected 1 argument, found 0 |
test/cases/compile_errors/missing_const_in_slice_with_nested_array_type.zig-2| ... | ... | @@ -12,7 +12,5 @@ export fn entry() void { |
| 12 | 12 | } |
| 13 | 13 | |
| 14 | 14 | // error |
| 15 | // backend=stage2 | |
| 16 | // target=native | |
| 17 | 15 | // |
| 18 | 16 | // :4:26: error: array literal requires address-of operator (&) to coerce to slice type '[][2]f32' |
test/cases/compile_errors/missing_digit_after_base.zig-2| ... | ... | @@ -4,7 +4,5 @@ export fn entry() void { |
| 4 | 4 | } |
| 5 | 5 | |
| 6 | 6 | // error |
| 7 | // backend=stage2 | |
| 8 | // target=native | |
| 9 | 7 | // |
| 10 | 8 | // :2:27: error: expected a digit after base prefix |
test/cases/compile_errors/missing_else_clause.zig-2| ... | ... | @@ -31,8 +31,6 @@ export fn entry() void { |
| 31 | 31 | k(true); |
| 32 | 32 | } |
| 33 | 33 | // error |
| 34 | // backend=stage2 | |
| 35 | // target=native | |
| 36 | 34 | // |
| 37 | 35 | // :2:20: error: expected type 'i32', found 'void' |
| 38 | 36 | // :8:15: error: incompatible types: 'i32' and 'void' |
test/cases/compile_errors/missing_field_in_struct_value_expression.zig-2| ... | ... | @@ -23,8 +23,6 @@ export fn h() void { |
| 23 | 23 | _ = c; |
| 24 | 24 | } |
| 25 | 25 | // error |
| 26 | // backend=stage2 | |
| 27 | // target=native | |
| 28 | 26 | // |
| 29 | 27 | // :9:16: error: missing struct field: x |
| 30 | 28 | // :1:11: note: struct declared here |
test/cases/compile_errors/missing_function_name.zig-2| ... | ... | @@ -1,7 +1,5 @@ |
| 1 | 1 | fn () void {} |
| 2 | 2 | |
| 3 | 3 | // error |
| 4 | // backend=stage2 | |
| 5 | // target=native | |
| 6 | 4 | // |
| 7 | 5 | // :1:1: error: missing function name |
test/cases/compile_errors/missing_function_proto_name.zig-2| ... | ... | @@ -1,7 +1,5 @@ |
| 1 | 1 | fn () void; |
| 2 | 2 | |
| 3 | 3 | // error |
| 4 | // backend=stage2 | |
| 5 | // target=native | |
| 6 | 4 | // |
| 7 | 5 | // :1:1: error: missing function name |
test/cases/compile_errors/missing_param_name.zig-2| ... | ... | @@ -4,7 +4,5 @@ export fn entry() usize { |
| 4 | 4 | } |
| 5 | 5 | |
| 6 | 6 | // error |
| 7 | // backend=stage2 | |
| 8 | // target=native | |
| 9 | 7 | // |
| 10 | 8 | // :1:6: error: missing parameter name |
test/cases/compile_errors/missing_parameter_name.zig-2| ... | ... | @@ -9,8 +9,6 @@ fn f1(x) u64 { |
| 9 | 9 | } |
| 10 | 10 | |
| 11 | 11 | // error |
| 12 | // backend=stage2 | |
| 13 | // target=native | |
| 14 | 12 | // |
| 15 | 13 | // :1:7: error: missing parameter name |
| 16 | 14 | // :4:7: error: missing parameter name |
test/cases/compile_errors/missing_parameter_name_of_generic_function.zig-2| ... | ... | @@ -5,7 +5,5 @@ export fn entry() void { |
| 5 | 5 | } |
| 6 | 6 | |
| 7 | 7 | // error |
| 8 | // backend=stage2 | |
| 9 | // target=native | |
| 10 | 8 | // |
| 11 | 9 | // :1:9: error: missing parameter name |
test/cases/compile_errors/missing_result_type_for_phi_node.zig-2| ... | ... | @@ -6,8 +6,6 @@ export fn entry() void { |
| 6 | 6 | } |
| 7 | 7 | |
| 8 | 8 | // error |
| 9 | // backend=stage2 | |
| 10 | // target=native | |
| 11 | 9 | // |
| 12 | 10 | // :5:11: error: incompatible types: 'void' and 'comptime_int' |
| 13 | 11 | // :5:11: note: type 'void' here |
test/cases/compile_errors/misspelled_type_with_pointer_only_reference.zig-2| ... | ... | @@ -29,7 +29,5 @@ fn foo() void { |
| 29 | 29 | } |
| 30 | 30 | |
| 31 | 31 | // error |
| 32 | // backend=stage2 | |
| 33 | // target=native | |
| 34 | 32 | // |
| 35 | 33 | // :5:16: error: use of undeclared identifier 'JsonList' |
test/cases/compile_errors/muladd_int_vector.zig-2| ... | ... | @@ -3,7 +3,5 @@ comptime { |
| 3 | 3 | } |
| 4 | 4 | |
| 5 | 5 | // error |
| 6 | // backend=stage2 | |
| 7 | // target=native | |
| 8 | 6 | // |
| 9 | 7 | // :2:9: error: expected vector of floats or float type, found '@Vector(1, u32)' |
test/cases/compile_errors/negative_zero_literal.zig-2| ... | ... | @@ -3,8 +3,6 @@ export fn foo() void { |
| 3 | 3 | } |
| 4 | 4 | |
| 5 | 5 | // error |
| 6 | // backend=stage2 | |
| 7 | // target=native | |
| 8 | 6 | // |
| 9 | 7 | // :2:10: error: integer literal '-0' is ambiguous |
| 10 | 8 | // :2:10: note: use '0' for an integer zero |
test/cases/compile_errors/nested_error_set_mismatch.zig-2| ... | ... | @@ -11,8 +11,6 @@ fn foo() ?OtherError!i32 { |
| 11 | 11 | } |
| 12 | 12 | |
| 13 | 13 | // error |
| 14 | // backend=stage2 | |
| 15 | // target=native | |
| 16 | 14 | // |
| 17 | 15 | // :5:34: error: expected type '?error{NextError}!i32', found '?error{OutOfMemory}!i32' |
| 18 | 16 | // :5:34: note: optional type child 'error{OutOfMemory}!i32' cannot cast into optional type child 'error{NextError}!i32' |
test/cases/compile_errors/nested_generic_function_param_type_mismatch.zig-2| ... | ... | @@ -16,8 +16,6 @@ pub export fn entry() void { |
| 16 | 16 | } |
| 17 | 17 | |
| 18 | 18 | // error |
| 19 | // backend=stage2 | |
| 20 | // target=native | |
| 21 | 19 | // |
| 22 | 20 | // :15:28: error: expected type '*const fn (type, u8, u8) u32', found '*const fn (void, u8, u8) u32' |
| 23 | 21 | // :15:28: note: pointer type child 'fn (void, u8, u8) u32' cannot cast into pointer type child 'fn (type, u8, u8) u32' |
test/cases/compile_errors/nested_ptr_cast_bad_operand.zig-2| ... | ... | @@ -11,8 +11,6 @@ export fn c() void { |
| 11 | 11 | } |
| 12 | 12 | |
| 13 | 13 | // error |
| 14 | // backend=stage2 | |
| 15 | // target=native | |
| 16 | 14 | // |
| 17 | 15 | // :3:45: error: null pointer casted to type '*const u32' |
| 18 | 16 | // :6:34: error: expected pointer type, found 'comptime_int' |
test/cases/compile_errors/nested_vectors.zig-2| ... | ... | @@ -6,7 +6,5 @@ export fn entry() void { |
| 6 | 6 | } |
| 7 | 7 | |
| 8 | 8 | // error |
| 9 | // backend=stage2 | |
| 10 | // target=native | |
| 11 | 9 | // |
| 12 | 10 | // :3:16: error: expected integer, float, bool, or pointer for the vector element type; found '@Vector(4, u8)' |
test/cases/compile_errors/no_else_prong_on_switch_on_global_error_set.zig-2| ... | ... | @@ -8,7 +8,5 @@ fn foo(a: anyerror) void { |
| 8 | 8 | } |
| 9 | 9 | |
| 10 | 10 | // error |
| 11 | // backend=stage2 | |
| 12 | // target=native | |
| 13 | 11 | // |
| 14 | 12 | // :5:5: error: else prong required when switching on type 'anyerror' |
test/cases/compile_errors/noalias_on_non_pointer_param.zig-2| ... | ... | @@ -16,7 +16,5 @@ comptime { |
| 16 | 16 | } |
| 17 | 17 | |
| 18 | 18 | // error |
| 19 | // backend=stage2 | |
| 20 | // target=native | |
| 21 | 19 | // |
| 22 | 20 | // :1:6: error: non-pointer parameter declared noalias |
test/cases/compile_errors/noalias_param_coersion.zig-2| ... | ... | @@ -11,8 +11,6 @@ fn foo(noalias _: *i32, noalias _: *i32) void {} |
| 11 | 11 | fn bar(noalias _: *i32, _: *i32) void {} |
| 12 | 12 | |
| 13 | 13 | // error |
| 14 | // backend=stage2 | |
| 15 | // target=native | |
| 16 | 14 | // |
| 17 | 15 | // :3:9: error: expected type 'fn (noalias *i32, noalias *i32) void', found 'fn (noalias *i32, *i32) void' |
| 18 | 16 | // :3:9: note: regular parameter 1 cannot cast into a noalias parameter |
test/cases/compile_errors/noinline_fn_cc_inline.zig-2| ... | ... | @@ -5,7 +5,5 @@ comptime { |
| 5 | 5 | } |
| 6 | 6 | |
| 7 | 7 | // error |
| 8 | // backend=stage2 | |
| 9 | // target=native | |
| 10 | 8 | // |
| 11 | 9 | // :1:29: error: 'noinline' function cannot have calling convention 'inline' |
test/cases/compile_errors/non-const_switch_number_literal.zig-2| ... | ... | @@ -11,8 +11,6 @@ fn bar() i32 { |
| 11 | 11 | } |
| 12 | 12 | |
| 13 | 13 | // error |
| 14 | // backend=stage2 | |
| 15 | // target=native | |
| 16 | 14 | // |
| 17 | 15 | // :2:15: error: value with comptime-only type 'comptime_int' depends on runtime control flow |
| 18 | 16 | // :2:26: note: runtime control flow here |
test/cases/compile_errors/non-const_variables_of_things_that_require_const_variables.zig-2| ... | ... | @@ -33,8 +33,6 @@ export fn entry8() void { |
| 33 | 33 | } |
| 34 | 34 | |
| 35 | 35 | // error |
| 36 | // backend=stage2 | |
| 37 | // target=native | |
| 38 | 36 | // |
| 39 | 37 | // :2:9: error: variable of type '*const comptime_int' must be const or comptime |
| 40 | 38 | // :6:9: error: variable of type '@TypeOf(undefined)' must be const or comptime |
test/cases/compile_errors/non-enum_tag_type_passed_to_union.zig-2| ... | ... | @@ -7,7 +7,5 @@ export fn entry() void { |
| 7 | 7 | } |
| 8 | 8 | |
| 9 | 9 | // error |
| 10 | // backend=stage2 | |
| 11 | // target=native | |
| 12 | 10 | // |
| 13 | 11 | // :1:19: error: expected enum tag type, found 'u32' |
test/cases/compile_errors/non-exhaustive_enum_field_non_final.zig-2| ... | ... | @@ -5,7 +5,5 @@ const B = enum(u1) { |
| 5 | 5 | }; |
| 6 | 6 | |
| 7 | 7 | // error |
| 8 | // backend=stage2 | |
| 9 | // target=native | |
| 10 | 8 | // |
| 11 | 9 | // :3:5: error: '_' field of non-exhaustive enum must be last |
test/cases/compile_errors/non-exhaustive_enum_marker_assigned_a_value.zig-2| ... | ... | @@ -14,8 +14,6 @@ comptime { |
| 14 | 14 | } |
| 15 | 15 | |
| 16 | 16 | // error |
| 17 | // backend=stage2 | |
| 18 | // target=native | |
| 19 | 17 | // |
| 20 | 18 | // :4:9: error: '_' is used to mark an enum as non-exhaustive and cannot be assigned a value |
| 21 | 19 | // :6:11: error: non-exhaustive enum missing integer tag type |
test/cases/compile_errors/non-exhaustive_enum_specifies_every_value.zig-2| ... | ... | @@ -8,7 +8,5 @@ pub export fn entry() void { |
| 8 | 8 | } |
| 9 | 9 | |
| 10 | 10 | // error |
| 11 | // backend=stage2 | |
| 12 | // target=native | |
| 13 | 11 | // |
| 14 | 12 | // :1:11: error: non-exhaustive enum specifies every value |
test/cases/compile_errors/non-extern_function_with_var_args.zig-2| ... | ... | @@ -4,7 +4,5 @@ export fn entry() void { |
| 4 | 4 | } |
| 5 | 5 | |
| 6 | 6 | // error |
| 7 | // backend=stage2 | |
| 8 | // target=native | |
| 9 | 7 | // |
| 10 | 8 | // :1:14: error: expected type expression, found '...' |
test/cases/compile_errors/non-inline_for_loop_on_a_type_that_requires_comptime.zig-2| ... | ... | @@ -10,8 +10,6 @@ export fn entry() void { |
| 10 | 10 | } |
| 11 | 11 | |
| 12 | 12 | // error |
| 13 | // backend=stage2 | |
| 14 | // target=native | |
| 15 | 13 | // |
| 16 | 14 | // :7:10: error: values of type '[2]tmp.Foo' must be comptime-known, but index value is runtime-known |
| 17 | 15 | // :3:8: note: struct requires comptime because of this field |
test/cases/compile_errors/non-integer_tag_type_to_automatic_union_enum.zig-2| ... | ... | @@ -7,7 +7,5 @@ export fn entry() void { |
| 7 | 7 | } |
| 8 | 8 | |
| 9 | 9 | // error |
| 10 | // backend=stage2 | |
| 11 | // target=native | |
| 12 | 10 | // |
| 13 | 11 | // :1:24: error: expected integer tag type, found 'f32' |
test/cases/compile_errors/non-integer_tag_type_to_enum.zig-2| ... | ... | @@ -7,7 +7,5 @@ export fn entry() void { |
| 7 | 7 | } |
| 8 | 8 | |
| 9 | 9 | // error |
| 10 | // backend=stage2 | |
| 11 | // target=native | |
| 12 | 10 | // |
| 13 | 11 | // :1:18: error: expected integer tag type, found 'f32' |
test/cases/compile_errors/non_constant_expression_in_array_size.zig-2| ... | ... | @@ -11,8 +11,6 @@ export fn entry() usize { |
| 11 | 11 | } |
| 12 | 12 | |
| 13 | 13 | // error |
| 14 | // backend=stage2 | |
| 15 | // target=native | |
| 16 | 14 | // |
| 17 | 15 | // :6:12: error: unable to resolve comptime value |
| 18 | 16 | // :2:12: note: called at comptime from here |
test/cases/compile_errors/non_error_sets_used_in_merge_error_sets_operator.zig-2| ... | ... | @@ -8,8 +8,6 @@ export fn bar() void { |
| 8 | 8 | } |
| 9 | 9 | |
| 10 | 10 | // error |
| 11 | // backend=stage2 | |
| 12 | // target=native | |
| 13 | 11 | // |
| 14 | 12 | // :2:20: error: expected error set type, found 'u8' |
| 15 | 13 | // :6:31: error: expected error set type, found 'u16' |
test/cases/compile_errors/non_float_passed_to_intFromFloat.zig-2| ... | ... | @@ -4,7 +4,5 @@ export fn entry() void { |
| 4 | 4 | } |
| 5 | 5 | |
| 6 | 6 | // error |
| 7 | // backend=stage2 | |
| 8 | // target=native | |
| 9 | 7 | // |
| 10 | 8 | // :2:34: error: expected float type, found 'i32' |
test/cases/compile_errors/non_int_passed_to_floatFromInt.zig-2| ... | ... | @@ -4,7 +4,5 @@ export fn entry() void { |
| 4 | 4 | } |
| 5 | 5 | |
| 6 | 6 | // error |
| 7 | // backend=stage2 | |
| 8 | // target=native | |
| 9 | 7 | // |
| 10 | 8 | // :2:34: error: expected integer type, found 'comptime_float' |
test/cases/compile_errors/non_pointer_given_to_intFromPtr.zig-2| ... | ... | @@ -3,7 +3,5 @@ export fn entry(x: i32) usize { |
| 3 | 3 | } |
| 4 | 4 | |
| 5 | 5 | // error |
| 6 | // backend=stage2 | |
| 7 | // target=native | |
| 8 | 6 | // |
| 9 | 7 | // :2:24: error: expected pointer, found 'i32' |
test/cases/compile_errors/non_void_error_union_payload_ignored.zig-2| ... | ... | @@ -18,8 +18,6 @@ pub export fn entry2() void { |
| 18 | 18 | } |
| 19 | 19 | |
| 20 | 20 | // error |
| 21 | // backend=stage2 | |
| 22 | // target=native | |
| 23 | 21 | // |
| 24 | 22 | // :3:5: error: error union payload is ignored |
| 25 | 23 | // :3:5: note: payload value can be explicitly ignored with '|_|' |
test/cases/compile_errors/noreturn_builtins_divert_control_flow.zig-2| ... | ... | @@ -12,8 +12,6 @@ export fn entry3() void { |
| 12 | 12 | } |
| 13 | 13 | |
| 14 | 14 | // error |
| 15 | // backend=stage2 | |
| 16 | // target=native | |
| 17 | 15 | // |
| 18 | 16 | // :3:5: error: unreachable code |
| 19 | 17 | // :2:5: note: control flow is diverted here |
test/cases/compile_errors/noreturn_struct_field.zig-2| ... | ... | @@ -6,7 +6,5 @@ comptime { |
| 6 | 6 | } |
| 7 | 7 | |
| 8 | 8 | // error |
| 9 | // backend=stage2 | |
| 10 | // target=native | |
| 11 | 9 | // |
| 12 | 10 | // :2:8: error: struct fields cannot be 'noreturn' |
test/cases/compile_errors/normal_string_with_newline.zig-2| ... | ... | @@ -2,7 +2,5 @@ const foo = "a |
| 2 | 2 | b"; |
| 3 | 3 | |
| 4 | 4 | // error |
| 5 | // backend=stage2 | |
| 6 | // target=native | |
| 7 | 5 | // |
| 8 | 6 | // :1:15: error: string literal contains invalid byte: '\n' |
test/cases/compile_errors/not_an_enum_type.zig-2| ... | ... | @@ -13,8 +13,6 @@ const InvalidToken = struct {}; |
| 13 | 13 | const ExpectedVarDeclOrFn = struct {}; |
| 14 | 14 | |
| 15 | 15 | // error |
| 16 | // backend=stage2 | |
| 17 | // target=native | |
| 18 | 16 | // |
| 19 | 17 | // :4:9: error: expected type '@typeInfo(tmp.Error).@"union".tag_type.?', found 'type' |
| 20 | 18 | // :8:15: note: enum declared here |
test/cases/compile_errors/number_literal_bad_exponent.zig-2| ... | ... | @@ -4,8 +4,6 @@ const c = 0x1E-4; |
| 4 | 4 | const d = 0x1E+4; |
| 5 | 5 | |
| 6 | 6 | // error |
| 7 | // backend=stage2 | |
| 8 | // target=native | |
| 9 | 7 | // |
| 10 | 8 | // :1:15: error: sign '-' cannot follow digit 'e' in hex base |
| 11 | 9 | // :2:15: error: sign '+' cannot follow digit 'e' in hex base |
test/cases/compile_errors/offsetOf-bad_field_name.zig-2| ... | ... | @@ -9,8 +9,6 @@ export fn foo() usize { |
| 9 | 9 | } |
| 10 | 10 | |
| 11 | 11 | // error |
| 12 | // backend=stage2 | |
| 13 | // target=native | |
| 14 | 12 | // |
| 15 | 13 | // :7:9: error: no field named 'a' in struct 'tmp.Foo' |
| 16 | 14 | // :1:13: note: struct declared here |
test/cases/compile_errors/offsetOf-non_struct.zig-2| ... | ... | @@ -4,7 +4,5 @@ export fn foo() usize { |
| 4 | 4 | } |
| 5 | 5 | |
| 6 | 6 | // error |
| 7 | // backend=stage2 | |
| 8 | // target=native | |
| 9 | 7 | // |
| 10 | 8 | // :3:22: error: expected struct type, found 'i32' |
test/cases/compile_errors/old_fn_ptr_in_extern_context.zig-2| ... | ... | @@ -9,8 +9,6 @@ comptime { |
| 9 | 9 | } |
| 10 | 10 | |
| 11 | 11 | // error |
| 12 | // backend=stage2 | |
| 13 | // target=native | |
| 14 | 12 | // |
| 15 | 13 | // :2:8: error: extern structs cannot contain fields of type 'fn () callconv(.c) void' |
| 16 | 14 | // :2:8: note: type has no guaranteed in-memory representation |
test/cases/compile_errors/only_equality_binary_operator_allowed_for_error_sets.zig-2| ... | ... | @@ -4,7 +4,5 @@ comptime { |
| 4 | 4 | } |
| 5 | 5 | |
| 6 | 6 | // error |
| 7 | // backend=stage2 | |
| 8 | // target=native | |
| 9 | 7 | // |
| 10 | 8 | // :2:23: error: operator > not allowed for type 'error{A,B}' |
test/cases/compile_errors/only_untyped_undef_coerces_to_all_types.zig-2| ... | ... | @@ -5,7 +5,5 @@ pub export fn entry() void { |
| 5 | 5 | } |
| 6 | 6 | |
| 7 | 7 | // error |
| 8 | // backend=stage2 | |
| 9 | // target=native | |
| 10 | 8 | // |
| 11 | 9 | // :3:20: error: expected type 'f32', found '[]u8' |
test/cases/compile_errors/opaque_type_with_field.zig-2| ... | ... | @@ -5,7 +5,5 @@ export fn entry() void { |
| 5 | 5 | } |
| 6 | 6 | |
| 7 | 7 | // error |
| 8 | // backend=stage2 | |
| 9 | // target=native | |
| 10 | 8 | // |
| 11 | 9 | // :1:25: error: opaque types cannot have fields |
test/cases/compile_errors/optional_empty_error_set.zig-2| ... | ... | @@ -6,8 +6,6 @@ fn foo() !void { |
| 6 | 6 | return x.?; |
| 7 | 7 | } |
| 8 | 8 | // error |
| 9 | // backend=stage2 | |
| 10 | // target=native | |
| 11 | 9 | // |
| 12 | 10 | // :6:13: error: unable to unwrap null |
| 13 | 11 | // :2:17: note: called at comptime here |
test/cases/compile_errors/out_of_bounds_index.zig-1| ... | ... | @@ -21,7 +21,6 @@ comptime { |
| 21 | 21 | } |
| 22 | 22 | |
| 23 | 23 | // error |
| 24 | // target=native | |
| 25 | 24 | // |
| 26 | 25 | // :4:32: error: end index 6 out of bounds for slice of length 4 +1 (sentinel) |
| 27 | 26 | // :9:28: error: end index 6 out of bounds for array of length 4 +1 (sentinel) |
test/cases/compile_errors/out_of_int_range_comptime_float_passed_to_intFromFloat.zig-2| ... | ... | @@ -4,7 +4,5 @@ export fn entry() void { |
| 4 | 4 | } |
| 5 | 5 | |
| 6 | 6 | // error |
| 7 | // backend=stage2 | |
| 8 | // target=native | |
| 9 | 7 | // |
| 10 | 8 | // :2:33: error: float value '200' cannot be stored in integer type 'i8' |
test/cases/compile_errors/overflow_in_enum_value_allocation.zig-2| ... | ... | @@ -8,7 +8,5 @@ pub export fn entry() void { |
| 8 | 8 | } |
| 9 | 9 | |
| 10 | 10 | // error |
| 11 | // backend=stage2 | |
| 12 | // target=native | |
| 13 | 11 | // |
| 14 | 12 | // :3:5: error: enumeration value '256' too large for type 'u8' |
test/cases/compile_errors/packed_struct_backing_int_wrong.zig-2| ... | ... | @@ -43,8 +43,6 @@ export fn entry7() void { |
| 43 | 43 | } |
| 44 | 44 | |
| 45 | 45 | // error |
| 46 | // backend=stage2 | |
| 47 | // target=native | |
| 48 | 46 | // |
| 49 | 47 | // :2:31: error: backing integer type 'u32' has bit size 32 but the struct fields have a total bit size of 29 |
| 50 | 48 | // :9:31: error: backing integer type 'i31' has bit size 31 but the struct fields have a total bit size of 32 |
test/cases/compile_errors/packed_struct_comparison.zig-2| ... | ... | @@ -22,8 +22,6 @@ const Foo = packed struct { |
| 22 | 22 | }; |
| 23 | 23 | |
| 24 | 24 | // error |
| 25 | // backend=stage2 | |
| 26 | // target=native | |
| 27 | 25 | // |
| 28 | 26 | // :5:11: error: operator > not allowed for type 'tmp.Foo' |
| 29 | 27 | // :19:20: note: struct declared here |
test/cases/compile_errors/packed_struct_with_fields_of_not_allowed_types.zig-2| ... | ... | @@ -78,8 +78,6 @@ export fn entry14() void { |
| 78 | 78 | } |
| 79 | 79 | |
| 80 | 80 | // error |
| 81 | // backend=stage2 | |
| 82 | // target=native | |
| 83 | 81 | // |
| 84 | 82 | // :3:12: error: packed structs cannot contain fields of type 'anyerror' |
| 85 | 83 | // :3:12: note: type has no guaranteed in-memory representation |
test/cases/compile_errors/packed_union_fields_mismatch.zig-2| ... | ... | @@ -6,8 +6,6 @@ export fn entry1() void { |
| 6 | 6 | } |
| 7 | 7 | |
| 8 | 8 | // error |
| 9 | // backend=stage2 | |
| 10 | // target=native | |
| 11 | 9 | // |
| 12 | 10 | // :2:16: error: packed union has fields with mismatching bit sizes |
| 13 | 11 | // :3:12: note: 1 bits here |
test/cases/compile_errors/packed_union_given_enum_tag_type.zig-2| ... | ... | @@ -14,7 +14,5 @@ export fn entry() void { |
| 14 | 14 | } |
| 15 | 15 | |
| 16 | 16 | // error |
| 17 | // backend=stage2 | |
| 18 | // target=native | |
| 19 | 17 | // |
| 20 | 18 | // :6:30: error: packed union does not support enum tag type |
test/cases/compile_errors/packed_union_with_automatic_layout_field.zig-2| ... | ... | @@ -12,8 +12,6 @@ export fn entry() void { |
| 12 | 12 | } |
| 13 | 13 | |
| 14 | 14 | // error |
| 15 | // backend=stage2 | |
| 16 | // target=native | |
| 17 | 15 | // |
| 18 | 16 | // :6:8: error: packed unions cannot contain fields of type 'tmp.Foo' |
| 19 | 17 | // :6:8: note: only packed structs layout are allowed in packed types |
test/cases/compile_errors/panic_called_at_compile_time.zig-2| ... | ... | @@ -7,7 +7,5 @@ export fn entry() void { |
| 7 | 7 | } |
| 8 | 8 | |
| 9 | 9 | // error |
| 10 | // backend=stage2 | |
| 11 | // target=native | |
| 12 | 10 | // |
| 13 | 11 | // :3:9: error: encountered @panic at comptime |
test/cases/compile_errors/panic_has_source_location.zig-2| ... | ... | @@ -11,7 +11,5 @@ pub fn panic(_: []const u8, _: ?*std.builtin.StackTrace, _: ?usize) noreturn { |
| 11 | 11 | } |
| 12 | 12 | |
| 13 | 13 | // error |
| 14 | // backend=stage2 | |
| 15 | // target=native | |
| 16 | 14 | // |
| 17 | 15 | // :10:5: error: panic |
test/cases/compile_errors/parameter_redeclaration.zig-2| ... | ... | @@ -4,8 +4,6 @@ export fn entry() void { |
| 4 | 4 | } |
| 5 | 5 | |
| 6 | 6 | // error |
| 7 | // backend=stage2 | |
| 8 | // target=native | |
| 9 | 7 | // |
| 10 | 8 | // :1:14: error: redeclaration of function parameter 'a' |
| 11 | 9 | // :1:6: note: previous declaration here |
test/cases/compile_errors/parameter_shadowing_global.zig-2| ... | ... | @@ -5,8 +5,6 @@ export fn entry() void { |
| 5 | 5 | } |
| 6 | 6 | |
| 7 | 7 | // error |
| 8 | // backend=stage2 | |
| 9 | // target=native | |
| 10 | 8 | // |
| 11 | 9 | // :2:6: error: function parameter shadows declaration of 'Foo' |
| 12 | 10 | // :1:1: note: declared here |
test/cases/compile_errors/pass_const_ptr_to_mutable_ptr_fn.zig-2| ... | ... | @@ -14,8 +14,6 @@ export fn entry() usize { |
| 14 | 14 | } |
| 15 | 15 | |
| 16 | 16 | // error |
| 17 | // backend=stage2 | |
| 18 | // target=native | |
| 19 | 17 | // |
| 20 | 18 | // :4:19: error: expected type '*[]const u8', found '*const []const u8' |
| 21 | 19 | // :4:19: note: cast discards const qualifier |
test/cases/compile_errors/passing_a_not-aligned-enough_pointer_to_cmpxchg.zig-2| ... | ... | @@ -6,8 +6,6 @@ export fn entry() bool { |
| 6 | 6 | } |
| 7 | 7 | |
| 8 | 8 | // error |
| 9 | // backend=stage2 | |
| 10 | // target=native | |
| 11 | 9 | // |
| 12 | 10 | // :4:31: error: expected type '*i32', found '*align(1) i32' |
| 13 | 11 | // :4:31: note: pointer alignment '1' cannot cast into pointer alignment '4' |
test/cases/compile_errors/passing_an_under-aligned_function_pointer.zig-1| ... | ... | @@ -9,7 +9,6 @@ fn alignedSmall() align(4) i32 { |
| 9 | 9 | } |
| 10 | 10 | |
| 11 | 11 | // error |
| 12 | // backend=stage2 | |
| 13 | 12 | // target=x86_64-linux |
| 14 | 13 | // |
| 15 | 14 | // :2:35: error: expected type '*align(8) const fn () i32', found '*align(4) const fn () i32' |
test/cases/compile_errors/peer_cast_then_implicit_cast_const_pointer_to_mutable_C_pointer.zig-2| ... | ... | @@ -4,8 +4,6 @@ export fn func() void { |
| 4 | 4 | } |
| 5 | 5 | |
| 6 | 6 | // error |
| 7 | // backend=stage2 | |
| 8 | // target=native | |
| 9 | 7 | // |
| 10 | 8 | // :3:32: error: expected type '[*c]u8', found '*const [0:0]u8' |
| 11 | 9 | // :3:32: note: cast discards const qualifier |
test/cases/compile_errors/pointer_arithmetic_on_pointer-to-array.zig-2| ... | ... | @@ -6,8 +6,6 @@ export fn foo() void { |
| 6 | 6 | } |
| 7 | 7 | |
| 8 | 8 | // error |
| 9 | // backend=stage2 | |
| 10 | // target=native | |
| 11 | 9 | // |
| 12 | 10 | // :4:17: error: incompatible types: '*[10]u8' and 'comptime_int' |
| 13 | 11 | // :4:15: note: type '*[10]u8' here |
test/cases/compile_errors/pointer_attributes_checked_when_coercing_pointer_to_anon_literal.zig-2| ... | ... | @@ -13,8 +13,6 @@ comptime { |
| 13 | 13 | } |
| 14 | 14 | |
| 15 | 15 | // error |
| 16 | // backend=stage2 | |
| 17 | // target=native | |
| 18 | 16 | // |
| 19 | 17 | // :2:29: error: expected type '[][]const u8', found '*const [2][]const u8' |
| 20 | 18 | // :2:29: note: cast discards const qualifier |
test/cases/compile_errors/pointer_to_anyopaque_slice.zig-2| ... | ... | @@ -6,7 +6,5 @@ export fn x() void { |
| 6 | 6 | } |
| 7 | 7 | |
| 8 | 8 | // error |
| 9 | // backend=stage2 | |
| 10 | // target=native | |
| 11 | 9 | // |
| 12 | 10 | // :4:9: error: expected type '[]anyopaque', found '*u32' |
test/cases/compile_errors/pointer_to_noreturn.zig-2| ... | ... | @@ -4,7 +4,5 @@ export fn entry() void { |
| 4 | 4 | } |
| 5 | 5 | |
| 6 | 6 | // error |
| 7 | // backend=stage2 | |
| 8 | // target=native | |
| 9 | 7 | // |
| 10 | 8 | // :1:9: error: pointer to noreturn not allowed |
test/cases/compile_errors/pointer_with_different_address_spaces.zig-1| ... | ... | @@ -7,7 +7,6 @@ export fn entry2() void { |
| 7 | 7 | |
| 8 | 8 | // error |
| 9 | 9 | // output_mode=Obj |
| 10 | // backend=stage2,llvm | |
| 11 | 10 | // target=x86_64-linux,x86_64-macos |
| 12 | 11 | // |
| 13 | 12 | // :2:12: error: expected type '*addrspace(.fs) i32', found '*addrspace(.gs) i32' |
test/cases/compile_errors/pointers_with_different_address_spaces.zig-1| ... | ... | @@ -7,7 +7,6 @@ pub fn main() void { |
| 7 | 7 | |
| 8 | 8 | // error |
| 9 | 9 | // output_mode=Exe |
| 10 | // backend=stage2,llvm | |
| 11 | 10 | // target=x86_64-linux,x86_64-macos |
| 12 | 11 | // |
| 13 | 12 | // :2:13: error: expected type '*i32', found '*addrspace(.gs) i32' |
test/cases/compile_errors/pointless discard.zig	-2| ... | ... | @@ -13,8 +13,6 @@ export fn bar() void { |
| 13 | 13 | } |
| 14 | 14 | |
| 15 | 15 | // error |
| 16 | // backend=stage2 | |
| 17 | // target=native | |
| 18 | 16 | // |
| 19 | 17 | // :4:9: error: pointless discard of local variable |
| 20 | 18 | // :3:5: note: used here |
test/cases/compile_errors/popCount-non-integer.zig-2| ... | ... | @@ -3,7 +3,5 @@ export fn entry(x: f32) u32 { |
| 3 | 3 | } |
| 4 | 4 | |
| 5 | 5 | // error |
| 6 | // backend=stage2 | |
| 7 | // target=native | |
| 8 | 6 | // |
| 9 | 7 | // :2:22: error: expected integer or vector, found 'f32' |
test/cases/compile_errors/primitives_take_precedence_over_declarations.zig-2| ... | ... | @@ -5,7 +5,5 @@ export fn entry() void { |
| 5 | 5 | } |
| 6 | 6 | |
| 7 | 7 | // error |
| 8 | // backend=stage2 | |
| 9 | // target=native | |
| 10 | 8 | // |
| 11 | 9 | // :3:19: error: type 'u8' cannot represent integer value '300' |
test/cases/compile_errors/ptrCast_discards_const_qualifier.zig-2| ... | ... | @@ -5,8 +5,6 @@ export fn entry() void { |
| 5 | 5 | } |
| 6 | 6 | |
| 7 | 7 | // error |
| 8 | // backend=stage2 | |
| 9 | // target=native | |
| 10 | 8 | // |
| 11 | 9 | // :3:21: error: @ptrCast discards const qualifier |
| 12 | 10 | // :3:21: note: use @constCast to discard const qualifier |
test/cases/compile_errors/ptrFromInt_non_ptr_type.zig-2| ... | ... | @@ -7,8 +7,6 @@ pub export fn entry2() void { |
| 7 | 7 | } |
| 8 | 8 | |
| 9 | 9 | // error |
| 10 | // backend=stage2 | |
| 11 | // target=native | |
| 12 | 10 | // |
| 13 | 11 | // :2:18: error: expected pointer type, found 'i32' |
| 14 | 12 | // :6:19: error: integer cannot be converted to slice type '[]u8' |
test/cases/compile_errors/ptrFromInt_with_misaligned_address.zig-2| ... | ... | @@ -4,7 +4,5 @@ pub export fn entry() void { |
| 4 | 4 | } |
| 5 | 5 | |
| 6 | 6 | // error |
| 7 | // backend=stage2 | |
| 8 | // target=native | |
| 9 | 7 | // |
| 10 | 8 | // :2:41: error: pointer type '[*]align(4) u8' requires aligned address |
test/cases/compile_errors/ptr_coerced_to_slice.zig-2| ... | ... | @@ -12,8 +12,6 @@ export fn baz() void { |
| 12 | 12 | } |
| 13 | 13 | |
| 14 | 14 | // error |
| 15 | // backend=stage2 | |
| 16 | // target=native | |
| 17 | 15 | // |
| 18 | 16 | // :3:25: error: expected type '[]const u8', found '[*]const u8' |
| 19 | 17 | // :7:25: error: expected type '[]const u8', found '[*c]const u8' |
test/cases/compile_errors/ptrcast_to_non-pointer.zig-2| ... | ... | @@ -3,7 +3,5 @@ export fn entry(a: *i32) usize { |
| 3 | 3 | } |
| 4 | 4 | |
| 5 | 5 | // error |
| 6 | // backend=stage2 | |
| 7 | // target=native | |
| 8 | 6 | // |
| 9 | 7 | // :2:12: error: expected pointer type, found 'usize' |
test/cases/compile_errors/range_operator_in_switch_used_on_error_set.zig-2| ... | ... | @@ -13,8 +13,6 @@ fn foo(x: i32) !void { |
| 13 | 13 | } |
| 14 | 14 | |
| 15 | 15 | // error |
| 16 | // backend=stage2 | |
| 17 | // target=native | |
| 18 | 16 | // |
| 19 | 17 | // :2:34: error: ranges not allowed when switching on type '@typeInfo(@typeInfo(@TypeOf(tmp.foo)).@"fn".return_type.?).error_union.error_set' |
| 20 | 18 | // :3:18: note: range here |
test/cases/compile_errors/reading_past_end_of_pointer_casted_array.zig-2| ... | ... | @@ -14,8 +14,6 @@ comptime { |
| 14 | 14 | } |
| 15 | 15 | |
| 16 | 16 | // error |
| 17 | // backend=stage2 | |
| 18 | // target=native | |
| 19 | 17 | // |
| 20 | 18 | // :5:26: error: dereference of '*const u24' exceeds bounds of containing decl of type '[4]u8' |
| 21 | 19 | // :12:26: error: dereference of '*const u32' exceeds bounds of containing decl of type '[4]u8' |
test/cases/compile_errors/reassign_to_array_parameter.zig-2| ... | ... | @@ -6,7 +6,5 @@ export fn entry() void { |
| 6 | 6 | } |
| 7 | 7 | |
| 8 | 8 | // error |
| 9 | // backend=stage2 | |
| 10 | // target=native | |
| 11 | 9 | // |
| 12 | 10 | // :2:5: error: cannot assign to constant |
test/cases/compile_errors/reassign_to_slice_parameter.zig-2| ... | ... | @@ -6,7 +6,5 @@ export fn entry() void { |
| 6 | 6 | } |
| 7 | 7 | |
| 8 | 8 | // error |
| 9 | // backend=stage2 | |
| 10 | // target=native | |
| 11 | 9 | // |
| 12 | 10 | // :2:5: error: cannot assign to constant |
test/cases/compile_errors/reassign_to_struct_parameter.zig-2| ... | ... | @@ -9,7 +9,5 @@ export fn entry() void { |
| 9 | 9 | } |
| 10 | 10 | |
| 11 | 11 | // error |
| 12 | // backend=stage2 | |
| 13 | // target=native | |
| 14 | 12 | // |
| 15 | 13 | // :5:5: error: cannot assign to constant |
test/cases/compile_errors/redefinition_of_enums.zig-2| ... | ... | @@ -2,8 +2,6 @@ const A = enum { x }; |
| 2 | 2 | const A = enum { x }; |
| 3 | 3 | |
| 4 | 4 | // error |
| 5 | // backend=stage2 | |
| 6 | // target=native | |
| 7 | 5 | // |
| 8 | 6 | // :1:7: error: duplicate struct member name 'A' |
| 9 | 7 | // :2:7: note: duplicate name here |
test/cases/compile_errors/redefinition_of_global_variables.zig-2| ... | ... | @@ -2,8 +2,6 @@ var a: i32 = 1; |
| 2 | 2 | var a: i32 = 2; |
| 3 | 3 | |
| 4 | 4 | // error |
| 5 | // backend=stage2 | |
| 6 | // target=native | |
| 7 | 5 | // |
| 8 | 6 | // :1:5: error: duplicate struct member name 'a' |
| 9 | 7 | // :2:5: note: duplicate name here |
test/cases/compile_errors/redefinition_of_struct.zig-2| ... | ... | @@ -2,8 +2,6 @@ const A = struct { x: i32 }; |
| 2 | 2 | const A = struct { y: i32 }; |
| 3 | 3 | |
| 4 | 4 | // error |
| 5 | // backend=stage2 | |
| 6 | // target=native | |
| 7 | 5 | // |
| 8 | 6 | // :1:7: error: duplicate struct member name 'A' |
| 9 | 7 | // :2:7: note: duplicate name here |
test/cases/compile_errors/redundant_ptr_cast.zig-2| ... | ... | @@ -11,8 +11,6 @@ export fn c() void { |
| 11 | 11 | } |
| 12 | 12 | |
| 13 | 13 | // error |
| 14 | // backend=stage2 | |
| 15 | // target=native | |
| 16 | 14 | // |
| 17 | 15 | // :3:18: error: redundant @ptrCast |
| 18 | 16 | // :6:44: error: redundant @alignCast |
test/cases/compile_errors/reference_to_const_data.zig-2| ... | ... | @@ -27,8 +27,6 @@ export fn quux() void { |
| 27 | 27 | } |
| 28 | 28 | |
| 29 | 29 | // error |
| 30 | // backend=stage2 | |
| 31 | // target=native | |
| 32 | 30 | // |
| 33 | 31 | // :3:8: error: cannot assign to constant |
| 34 | 32 | // :7:8: error: cannot assign to constant |
test/cases/compile_errors/regression_test_2980_base_type_u32_is_not_type_checked_properly_when_assigning_a_value_within_a_struct.zig-2| ... | ... | @@ -15,8 +15,6 @@ export fn entry() void { |
| 15 | 15 | } |
| 16 | 16 | |
| 17 | 17 | // error |
| 18 | // backend=stage2 | |
| 19 | // target=native | |
| 20 | 18 | // |
| 21 | 19 | // :12:15: error: expected type 'u32', found '@typeInfo(@typeInfo(@TypeOf(tmp.get_uval)).@"fn".return_type.?).error_union.error_set!u32' |
| 22 | 20 | // :12:15: note: cannot convert error union to payload type |
test/cases/compile_errors/reified_enum_field_value_overflow.zig-2| ... | ... | @@ -13,7 +13,5 @@ comptime { |
| 13 | 13 | } |
| 14 | 14 | |
| 15 | 15 | // error |
| 16 | // target=native | |
| 17 | // backend=stage2 | |
| 18 | 16 | // |
| 19 | 17 | // :2:15: error: field 'f2' with enumeration value '2' is too large for backing int type 'u1' |
test/cases/compile_errors/reify_enum_with_duplicate_field.zig-2| ... | ... | @@ -13,8 +13,6 @@ export fn entry() void { |
| 13 | 13 | } |
| 14 | 14 | |
| 15 | 15 | // error |
| 16 | // backend=stage2 | |
| 17 | // target=native | |
| 18 | 16 | // |
| 19 | 17 | // :2:9: error: duplicate enum field 'A' |
| 20 | 18 | // :2:9: note: other field here |
test/cases/compile_errors/reify_enum_with_duplicate_tag_value.zig-2| ... | ... | @@ -13,8 +13,6 @@ export fn entry() void { |
| 13 | 13 | } |
| 14 | 14 | |
| 15 | 15 | // error |
| 16 | // backend=stage2 | |
| 17 | // target=native | |
| 18 | 16 | // |
| 19 | 17 | // :2:9: error: enum tag value 10 already taken |
| 20 | 18 | // :2:9: note: other enum tag value here |
test/cases/compile_errors/reify_type.Fn_with_is_generic_true.zig-2| ... | ... | @@ -12,7 +12,5 @@ comptime { |
| 12 | 12 | } |
| 13 | 13 | |
| 14 | 14 | // error |
| 15 | // backend=stage2 | |
| 16 | // target=native | |
| 17 | 15 | // |
| 18 | 16 | // :1:13: error: Type.Fn.is_generic must be false for @Type |
test/cases/compile_errors/reify_type.Fn_with_return_type_null.zig-2| ... | ... | @@ -12,7 +12,5 @@ comptime { |
| 12 | 12 | } |
| 13 | 13 | |
| 14 | 14 | // error |
| 15 | // backend=stage2 | |
| 16 | // target=native | |
| 17 | 15 | // |
| 18 | 16 | // :1:13: error: Type.Fn.return_type must be non-null for @Type |
test/cases/compile_errors/reify_typeOf_with_incompatible_arguments.zig-2| ... | ... | @@ -6,8 +6,6 @@ export fn entry() void { |
| 6 | 6 | } |
| 7 | 7 | |
| 8 | 8 | // error |
| 9 | // backend=stage2 | |
| 10 | // target=native | |
| 11 | 9 | // |
| 12 | 10 | // :4:9: error: incompatible types: 'f32' and 'u32' |
| 13 | 11 | // :4:17: note: type 'f32' here |
test/cases/compile_errors/reify_typeOf_with_no_arguments.zig-2| ... | ... | @@ -3,7 +3,5 @@ export fn entry() void { |
| 3 | 3 | } |
| 4 | 4 | |
| 5 | 5 | // error |
| 6 | // backend=stage2 | |
| 7 | // target=native | |
| 8 | 6 | // |
| 9 | 7 | // :2:9: error: expected at least 1 argument, found 0 |
test/cases/compile_errors/reify_type_for_exhaustive_enum_with_non-integer_tag_type.zig-2| ... | ... | @@ -11,7 +11,5 @@ export fn entry() void { |
| 11 | 11 | } |
| 12 | 12 | |
| 13 | 13 | // error |
| 14 | // backend=stage2 | |
| 15 | // target=native | |
| 16 | 14 | // |
| 17 | 15 | // :1:13: error: Type.Enum.tag_type must be an integer type |
test/cases/compile_errors/reify_type_for_tagged_extern_union.zig-2| ... | ... | @@ -28,7 +28,5 @@ export fn entry() void { |
| 28 | 28 | } |
| 29 | 29 | |
| 30 | 30 | // error |
| 31 | // backend=stage2 | |
| 32 | // target=native | |
| 33 | 31 | // |
| 34 | 32 | // :13:16: error: extern union does not support enum tag type |
test/cases/compile_errors/reify_type_for_tagged_packed_union.zig-2| ... | ... | @@ -28,7 +28,5 @@ export fn entry() void { |
| 28 | 28 | } |
| 29 | 29 | |
| 30 | 30 | // error |
| 31 | // backend=stage2 | |
| 32 | // target=native | |
| 33 | 31 | // |
| 34 | 32 | // :13:16: error: packed union does not support enum tag type |
test/cases/compile_errors/reify_type_for_tagged_union_with_extra_enum_field.zig-2| ... | ... | @@ -27,8 +27,6 @@ export fn entry() void { |
| 27 | 27 | } |
| 28 | 28 | |
| 29 | 29 | // error |
| 30 | // backend=stage2 | |
| 31 | // target=native | |
| 32 | 30 | // |
| 33 | 31 | // :13:16: error: enum fields missing in union |
| 34 | 32 | // :1:13: note: field 'arst' missing, declared here |
test/cases/compile_errors/reify_type_for_tagged_union_with_extra_union_field.zig-2| ... | ... | @@ -27,8 +27,6 @@ export fn entry() void { |
| 27 | 27 | } |
| 28 | 28 | |
| 29 | 29 | // error |
| 30 | // backend=stage2 | |
| 31 | // target=native | |
| 32 | 30 | // |
| 33 | 31 | // :12:16: error: no field named 'arst' in enum 'tmp.Tag' |
| 34 | 32 | // :1:13: note: enum declared here |
test/cases/compile_errors/reify_type_for_tagged_union_with_no_enum_fields.zig-2| ... | ... | @@ -23,8 +23,6 @@ export fn entry() void { |
| 23 | 23 | } |
| 24 | 24 | |
| 25 | 25 | // error |
| 26 | // backend=stage2 | |
| 27 | // target=native | |
| 28 | 26 | // |
| 29 | 27 | // :9:16: error: no field named 'signed' in enum 'tmp.Tag' |
| 30 | 28 | // :1:13: note: enum declared here |
test/cases/compile_errors/reify_type_for_tagged_union_with_no_union_fields.zig-2| ... | ... | @@ -23,8 +23,6 @@ export fn entry() void { |
| 23 | 23 | } |
| 24 | 24 | |
| 25 | 25 | // error |
| 26 | // backend=stage2 | |
| 27 | // target=native | |
| 28 | 26 | // |
| 29 | 27 | // :12:16: error: enum fields missing in union |
| 30 | 28 | // :1:13: note: field 'signed' missing, declared here |
test/cases/compile_errors/reify_type_for_union_with_opaque_field.zig-2| ... | ... | @@ -13,8 +13,6 @@ export fn entry() usize { |
| 13 | 13 | } |
| 14 | 14 | |
| 15 | 15 | // error |
| 16 | // backend=stage2 | |
| 17 | // target=native | |
| 18 | 16 | // |
| 19 | 17 | // :1:18: error: opaque types have unknown size and therefore cannot be directly embedded in unions |
| 20 | 18 | // :6:39: note: opaque declared here |
test/cases/compile_errors/reify_type_with_Type.Int.zig-2| ... | ... | @@ -7,8 +7,6 @@ export fn entry() void { |
| 7 | 7 | } |
| 8 | 8 | |
| 9 | 9 | // error |
| 10 | // backend=stage2 | |
| 11 | // target=native | |
| 12 | 10 | // |
| 13 | 11 | // :3:31: error: expected type 'builtin.Type', found 'builtin.Type.Int' |
| 14 | 12 | // :?:?: note: struct declared here |
test/cases/compile_errors/reject_extern_function_definitions_with_body.zig-2| ... | ... | @@ -3,7 +3,5 @@ extern "c" fn definitelyNotInLibC(a: i32, b: i32) i32 { |
| 3 | 3 | } |
| 4 | 4 | |
| 5 | 5 | // error |
| 6 | // backend=stage2 | |
| 7 | // target=native | |
| 8 | 6 | // |
| 9 | 7 | // :1:1: error: extern functions have no body |
test/cases/compile_errors/reject_extern_variables_with_initializers.zig-2| ... | ... | @@ -1,7 +1,5 @@ |
| 1 | 1 | extern var foo: int = 2; |
| 2 | 2 | |
| 3 | 3 | // error |
| 4 | // backend=stage2 | |
| 5 | // target=native | |
| 6 | 4 | // |
| 7 | 5 | // :1:23: error: extern variables have no initializers |
test/cases/compile_errors/repeated_invalid_field_access_to_generic_function_returning_type_crashes_compiler_2655.zig-2| ... | ... | @@ -7,8 +7,6 @@ test "1" { |
| 7 | 7 | } |
| 8 | 8 | |
| 9 | 9 | // error |
| 10 | // backend=stage2 | |
| 11 | // target=native | |
| 12 | 10 | // is_test=true |
| 13 | 11 | // |
| 14 | 12 | // :2:12: error: use of undeclared identifier 'Q' |
test/cases/compile_errors/resolve_inferred_error_set_of_generic_fn.zig-2| ... | ... | @@ -11,8 +11,6 @@ export fn entry() void { |
| 11 | 11 | } |
| 12 | 12 | |
| 13 | 13 | // error |
| 14 | // backend=stage2 | |
| 15 | // target=native | |
| 16 | 14 | // |
| 17 | 15 | // :10:15: error: unable to resolve inferred error set of generic function |
| 18 | 16 | // :1:1: note: generic function declared here |
test/cases/compile_errors/result_location_incompatibility_mismatching_handle_is_ptr.zig-2| ... | ... | @@ -12,8 +12,6 @@ pub const Container = struct { |
| 12 | 12 | }; |
| 13 | 13 | |
| 14 | 14 | // error |
| 15 | // backend=stage2 | |
| 16 | // target=native | |
| 17 | 15 | // |
| 18 | 16 | // :3:23: error: expected type 'i32', found '?i32' |
| 19 | 17 | // :3:23: note: cannot convert optional to payload type |
test/cases/compile_errors/result_location_incompatibility_mismatching_handle_is_ptr_generic_call.zig-2| ... | ... | @@ -12,8 +12,6 @@ pub const Container = struct { |
| 12 | 12 | }; |
| 13 | 13 | |
| 14 | 14 | // error |
| 15 | // backend=stage2 | |
| 16 | // target=native | |
| 17 | 15 | // |
| 18 | 16 | // :3:23: error: expected type 'i32', found '?i32' |
| 19 | 17 | // :3:23: note: cannot convert optional to payload type |
test/cases/compile_errors/return_from_defer_expression.zig-2| ... | ... | @@ -17,8 +17,6 @@ export fn entry() usize { |
| 17 | 17 | } |
| 18 | 18 | |
| 19 | 19 | // error |
| 20 | // backend=stage2 | |
| 21 | // target=native | |
| 22 | 20 | // |
| 23 | 21 | // :4:11: error: 'try' not allowed inside defer expression |
| 24 | 22 | // :4:5: note: defer expression here |
test/cases/compile_errors/return_from_naked_function.zig-2| ... | ... | @@ -7,8 +7,6 @@ comptime { |
| 7 | 7 | } |
| 8 | 8 | |
| 9 | 9 | // error |
| 10 | // backend=stage2 | |
| 11 | // target=native | |
| 12 | 10 | // |
| 13 | 11 | // :2:5: error: cannot return from naked function |
| 14 | 12 | // :2:5: note: can only return using assembly |
test/cases/compile_errors/return_incompatible_generic_struct.zig-2| ... | ... | @@ -12,8 +12,6 @@ export fn entry() void { |
| 12 | 12 | } |
| 13 | 13 | |
| 14 | 14 | // error |
| 15 | // backend=stage2 | |
| 16 | // target=native | |
| 17 | 15 | // |
| 18 | 16 | // :8:18: error: expected type 'tmp.A(u32)', found 'tmp.B(u32)' |
| 19 | 17 | // :5:12: note: struct declared here |
test/cases/compile_errors/return_invalid_type_from_test.zig-2| ... | ... | @@ -3,8 +3,6 @@ test "example" { |
| 3 | 3 | } |
| 4 | 4 | |
| 5 | 5 | // error |
| 6 | // backend=stage2 | |
| 7 | // target=native | |
| 8 | 6 | // is_test=true |
| 9 | 7 | // |
| 10 | 8 | // :2:12: error: expected type 'anyerror!void', found 'comptime_int' |
test/cases/compile_errors/return_undefined_from_noreturn.zig-2| ... | ... | @@ -3,8 +3,6 @@ export fn entry() noreturn { |
| 3 | 3 | } |
| 4 | 4 | |
| 5 | 5 | // error |
| 6 | // backend=stage2 | |
| 7 | // target=native | |
| 8 | 6 | // |
| 9 | 7 | // :2:12: error: function declared 'noreturn' returns |
| 10 | 8 | // :1:19: note: 'noreturn' declared here |
test/cases/compile_errors/runtime_@ptrFromInt_to_comptime_only_type.zig-1| ... | ... | @@ -9,7 +9,6 @@ pub export fn callbackFin(id: c_int, arg: ?*anyopaque) void { |
| 9 | 9 | } |
| 10 | 10 | |
| 11 | 11 | // error |
| 12 | // target=native | |
| 13 | 12 | // |
| 14 | 13 | // :5:54: error: pointer to comptime-only type '?*tmp.GuSettings' must be comptime-known, but operand is runtime-known |
| 15 | 14 | // :2:10: note: struct requires comptime because of this field |
test/cases/compile_errors/runtime_cast_to_union_which_has_non-void_fields.zig-2| ... | ... | @@ -13,8 +13,6 @@ fn foo(l: Letter) void { |
| 13 | 13 | } |
| 14 | 14 | |
| 15 | 15 | // error |
| 16 | // backend=stage2 | |
| 17 | // target=native | |
| 18 | 16 | // |
| 19 | 17 | // :11:22: error: runtime coercion from enum 'tmp.Letter' to union 'tmp.Value' which has non-void fields |
| 20 | 18 | // :3:5: note: field 'A' has type 'i32' |
test/cases/compile_errors/runtime_index_into_comptime_type_slice.zig-2| ... | ... | @@ -11,8 +11,6 @@ export fn entry() void { |
| 11 | 11 | } |
| 12 | 12 | |
| 13 | 13 | // error |
| 14 | // backend=stage2 | |
| 15 | // target=native | |
| 16 | 14 | // |
| 17 | 15 | // :9:54: error: values of type '[]const builtin.Type.StructField' must be comptime-known, but index value is runtime-known |
| 18 | 16 | // : note: struct requires comptime because of this field |
test/cases/compile_errors/runtime_indexing_comptime_array.zig-2| ... | ... | @@ -23,8 +23,6 @@ pub export fn entry3() void { |
| 23 | 23 | _ = &i; |
| 24 | 24 | } |
| 25 | 25 | // error |
| 26 | // target=native | |
| 27 | // backend=stage2 | |
| 28 | 26 | // |
| 29 | 27 | // :7:10: error: values of type '[2]fn () void' must be comptime-known, but index value is runtime-known |
| 30 | 28 | // :7:10: note: use '*const fn () void' for a function pointer type |
test/cases/compile_errors/runtime_to_comptime_num.zig-2| ... | ... | @@ -22,8 +22,6 @@ pub export fn entry4() void { |
| 22 | 22 | } |
| 23 | 23 | |
| 24 | 24 | // error |
| 25 | // backend=stage2 | |
| 26 | // target=native | |
| 27 | 25 | // |
| 28 | 26 | // :4:27: error: unable to resolve comptime value |
| 29 | 27 | // :4:27: note: value casted to 'comptime_int' must be comptime-known |
test/cases/compile_errors/runtime_value_in_switch_prong.zig-2| ... | ... | @@ -7,8 +7,6 @@ pub export fn entry() void { |
| 7 | 7 | } |
| 8 | 8 | |
| 9 | 9 | // error |
| 10 | // backend=stage2 | |
| 11 | // target=native | |
| 12 | 10 | // |
| 13 | 11 | // :4:9: error: unable to resolve comptime value |
| 14 | 12 | // :4:9: note: switch prong values must be comptime-known |
test/cases/compile_errors/saturating_arithmetic_does_not_allow_floats.zig-2| ... | ... | @@ -3,7 +3,5 @@ export fn a() void { |
| 3 | 3 | } |
| 4 | 4 | |
| 5 | 5 | // error |
| 6 | // backend=stage2 | |
| 7 | // target=native | |
| 8 | 6 | // |
| 9 | 7 | // :2:23: error: invalid operands to binary expression: 'float' and 'float' |
test/cases/compile_errors/saturating_shl_does_not_allow_negative_rhs.zig-2| ... | ... | @@ -25,8 +25,6 @@ export fn d(rhs: @Vector(3, i32)) void { |
| 25 | 25 | } |
| 26 | 26 | |
| 27 | 27 | // error |
| 28 | // backend=stage2 | |
| 29 | // target=native | |
| 30 | 28 | // |
| 31 | 29 | // :2:25: error: shift by negative amount '-1' |
| 32 | 30 | // :7:12: error: shift by negative amount '-2' |
test/cases/compile_errors/self_referential_struct_requires_comptime.zig-2| ... | ... | @@ -8,8 +8,6 @@ pub export fn entry() void { |
| 8 | 8 | } |
| 9 | 9 | |
| 10 | 10 | // error |
| 11 | // backend=stage2 | |
| 12 | // target=native | |
| 13 | 11 | // |
| 14 | 12 | // :6:12: error: variable of type 'tmp.S' must be const or comptime |
| 15 | 13 | // :2:8: note: struct requires comptime because of this field |
test/cases/compile_errors/self_referential_union_requires_comptime.zig-2| ... | ... | @@ -8,8 +8,6 @@ pub export fn entry() void { |
| 8 | 8 | } |
| 9 | 9 | |
| 10 | 10 | // error |
| 11 | // backend=stage2 | |
| 12 | // target=native | |
| 13 | 11 | // |
| 14 | 12 | // :6:12: error: variable of type 'tmp.U' must be const or comptime |
| 15 | 13 | // :2:8: note: union requires comptime because of this field |
test/cases/compile_errors/setting_a_section_on_a_local_variable.zig-2| ... | ... | @@ -4,7 +4,5 @@ export fn entry() i32 { |
| 4 | 4 | } |
| 5 | 5 | |
| 6 | 6 | // error |
| 7 | // backend=stage2 | |
| 8 | // target=native | |
| 9 | 7 | // |
| 10 | 8 | // :2:30: error: cannot set section of local variable 'foo' |
test/cases/compile_errors/shift_amount_has_to_be_an_integer_type.zig-2| ... | ... | @@ -4,8 +4,6 @@ export fn entry() void { |
| 4 | 4 | } |
| 5 | 5 | |
| 6 | 6 | // error |
| 7 | // backend=stage2 | |
| 8 | // target=native | |
| 9 | 7 | // |
| 10 | 8 | // :2:20: error: expected type 'comptime_int', found pointer |
| 11 | 9 | // :2:20: note: address-of operator always returns a pointer |
test/cases/compile_errors/shift_by_negative_comptime_integer.zig-2| ... | ... | @@ -4,7 +4,5 @@ comptime { |
| 4 | 4 | } |
| 5 | 5 | |
| 6 | 6 | // error |
| 7 | // backend=stage2 | |
| 8 | // target=native | |
| 9 | 7 | // |
| 10 | 8 | // :2:20: error: shift by negative amount '-1' |
test/cases/compile_errors/shift_on_type_with_non-power-of-two_size.zig-2| ... | ... | @@ -28,8 +28,6 @@ export fn entry() void { |
| 28 | 28 | } |
| 29 | 29 | |
| 30 | 30 | // error |
| 31 | // backend=stage2 | |
| 32 | // target=native | |
| 33 | 31 | // |
| 34 | 32 | // :6:22: error: shift amount '24' is too large for operand type 'u24' |
| 35 | 33 | // :11:22: error: shift amount '24' is too large for operand type 'u24' |
test/cases/compile_errors/shifting_RHS_is_log2_of_LHS_int_bit_width.zig-2| ... | ... | @@ -3,8 +3,6 @@ export fn entry(x: u8, y: u8) u8 { |
| 3 | 3 | } |
| 4 | 4 | |
| 5 | 5 | // error |
| 6 | // backend=stage2 | |
| 7 | // target=native | |
| 8 | 6 | // |
| 9 | 7 | // :2:17: error: expected type 'u3', found 'u8' |
| 10 | 8 | // :2:17: note: unsigned 3-bit int cannot represent all possible unsigned 8-bit values |
test/cases/compile_errors/shifting_without_int_type_or_comptime_known.zig-2| ... | ... | @@ -16,8 +16,6 @@ export fn entry3() void { |
| 16 | 16 | } |
| 17 | 17 | |
| 18 | 18 | // error |
| 19 | // backend=stage2 | |
| 20 | // target=native | |
| 21 | 19 | // |
| 22 | 20 | // :2:17: error: LHS of shift must be a fixed-width integer type, or RHS must be comptime-known |
| 23 | 21 | // :5:17: error: LHS of shift must be a fixed-width integer type, or RHS must be comptime-known |
test/cases/compile_errors/shlExact_shifts_out_1_bits.zig-2| ... | ... | @@ -4,7 +4,5 @@ comptime { |
| 4 | 4 | } |
| 5 | 5 | |
| 6 | 6 | // error |
| 7 | // backend=stage2 | |
| 8 | // target=native | |
| 9 | 7 | // |
| 10 | 8 | // :2:15: error: overflow of integer type 'u8' with value '340' |
test/cases/compile_errors/shrExact_shifts_out_1_bits.zig-2| ... | ... | @@ -4,7 +4,5 @@ comptime { |
| 4 | 4 | } |
| 5 | 5 | |
| 6 | 6 | // error |
| 7 | // backend=stage2 | |
| 8 | // target=native | |
| 9 | 7 | // |
| 10 | 8 | // :2:15: error: exact shift shifted out 1 bits |
test/cases/compile_errors/signed_integer_division.zig-2| ... | ... | @@ -3,7 +3,5 @@ export fn foo(a: i32, b: i32) i32 { |
| 3 | 3 | } |
| 4 | 4 | |
| 5 | 5 | // error |
| 6 | // backend=stage2 | |
| 7 | // target=native | |
| 8 | 6 | // |
| 9 | 7 | // :2:14: error: division with 'i32' and 'i32': signed integers must use @divTrunc, @divFloor, or @divExact |
test/cases/compile_errors/sizeOf_bad_type.zig-2| ... | ... | @@ -3,7 +3,5 @@ export fn entry() usize { |
| 3 | 3 | } |
| 4 | 4 | |
| 5 | 5 | // error |
| 6 | // backend=stage2 | |
| 7 | // target=native | |
| 8 | 6 | // |
| 9 | 7 | // :2:20: error: no size available for type '@TypeOf(null)' |
test/cases/compile_errors/slice_cannot_have_its_bytes_reinterpreted.zig-2| ... | ... | @@ -4,7 +4,5 @@ export fn foo() void { |
| 4 | 4 | } |
| 5 | 5 | |
| 6 | 6 | // error |
| 7 | // backend=stage2 | |
| 8 | // target=native | |
| 9 | 7 | // |
| 10 | 8 | // :3:49: error: comptime dereference requires '[]const u8' to have a well-defined layout |
test/cases/compile_errors/slice_of_non_array_type.zig-2| ... | ... | @@ -3,7 +3,5 @@ comptime { |
| 3 | 3 | } |
| 4 | 4 | |
| 5 | 5 | // error |
| 6 | // backend=stage2 | |
| 7 | // target=native | |
| 8 | 6 | // |
| 9 | 7 | // :2:10: error: slice of non-array type 'comptime_int' |
test/cases/compile_errors/slice_of_null_pointer.zig-1| ... | ... | @@ -6,6 +6,5 @@ comptime { |
| 6 | 6 | } |
| 7 | 7 | |
| 8 | 8 | // error |
| 9 | // target=native | |
| 10 | 9 | // |
| 11 | 10 | // :5:10: error: slice of null pointer |
test/cases/compile_errors/slice_passed_as_array_init_type.zig-2| ... | ... | @@ -4,8 +4,6 @@ export fn entry() void { |
| 4 | 4 | } |
| 5 | 5 | |
| 6 | 6 | // error |
| 7 | // backend=stage2 | |
| 8 | // target=native | |
| 9 | 7 | // |
| 10 | 8 | // :2:19: error: type '[]u8' does not support array initialization syntax |
| 11 | 9 | // :2:19: note: inferred array length is specified with an underscore: '[_]u8' |
test/cases/compile_errors/slice_passed_as_array_init_type_with_elems.zig-2| ... | ... | @@ -4,8 +4,6 @@ export fn entry() void { |
| 4 | 4 | } |
| 5 | 5 | |
| 6 | 6 | // error |
| 7 | // backend=stage2 | |
| 8 | // target=native | |
| 9 | 7 | // |
| 10 | 8 | // :2:15: error: type '[]u8' does not support array initialization syntax |
| 11 | 9 | // :2:15: note: inferred array length is specified with an underscore: '[_]u8' |
test/cases/compile_errors/slice_sentinel_mismatch-1.zig-2| ... | ... | @@ -9,8 +9,6 @@ export fn entry2() void { |
| 9 | 9 | } |
| 10 | 10 | |
| 11 | 11 | // error |
| 12 | // backend=stage2 | |
| 13 | // target=native | |
| 14 | 12 | // |
| 15 | 13 | // :2:37: error: expected type '[2:1]u8', found '[2:2]u8' |
| 16 | 14 | // :2:37: note: array sentinel '2' cannot cast into array sentinel '1' |
test/cases/compile_errors/slice_sentinel_mismatch-2.zig-2| ... | ... | @@ -7,8 +7,6 @@ comptime { |
| 7 | 7 | } |
| 8 | 8 | |
| 9 | 9 | // error |
| 10 | // backend=stage2 | |
| 11 | // target=native | |
| 12 | 10 | // |
| 13 | 11 | // :3:12: error: expected type '[:0]u8', found '[]u8' |
| 14 | 12 | // :3:12: note: destination pointer requires '0' sentinel |
test/cases/compile_errors/slice_to_anyopaque_pointer.zig-2| ... | ... | @@ -5,8 +5,6 @@ export fn entry() void { |
| 5 | 5 | } |
| 6 | 6 | |
| 7 | 7 | // error |
| 8 | // backend=stage2 | |
| 9 | // target=native | |
| 10 | 8 | // |
| 11 | 9 | // :3:37: error: expected type '*const anyopaque', found '[]const u8' |
| 12 | 10 | // :3:37: note: cannot implicitly cast slice '[]const u8' to anyopaque pointer '*const anyopaque' |
test/cases/compile_errors/specify_non-integer_enum_tag_type.zig-2| ... | ... | @@ -10,7 +10,5 @@ export fn entry() void { |
| 10 | 10 | } |
| 11 | 11 | |
| 12 | 12 | // error |
| 13 | // backend=stage2 | |
| 14 | // target=native | |
| 15 | 13 | // |
| 16 | 14 | // :1:20: error: expected integer tag type, found 'f32' |
test/cases/compile_errors/spirv_merge_logical_pointers.zig-1| ... | ... | @@ -11,7 +11,6 @@ export fn a() void { |
| 11 | 11 | } |
| 12 | 12 | |
| 13 | 13 | // error |
| 14 | // backend=stage2 | |
| 15 | 14 | // target=spirv64-vulkan |
| 16 | 15 | // |
| 17 | 16 | // :9:13: error: value with non-mergable pointer type '*i32' depends on runtime control flow |
test/cases/compile_errors/std.fmt_error_for_unused_arguments.zig-2| ... | ... | @@ -3,7 +3,5 @@ export fn entry() void { |
| 3 | 3 | } |
| 4 | 4 | |
| 5 | 5 | // error |
| 6 | // backend=stage2 | |
| 7 | // target=native | |
| 8 | 6 | // |
| 9 | 7 | // :?:?: error: 10 unused arguments in '{d} {d} {d} {d} {d}' |
test/cases/compile_errors/store_vector_pointer_with_unknown_runtime_index.zig-2| ... | ... | @@ -11,7 +11,5 @@ fn storev(ptr: anytype, val: i31) void { |
| 11 | 11 | } |
| 12 | 12 | |
| 13 | 13 | // error |
| 14 | // backend=stage2 | |
| 15 | // target=native | |
| 16 | 14 | // |
| 17 | 15 | // :10:8: error: unable to determine vector element index of type '*align(16:0:4:?) i31' |
test/cases/compile_errors/struct_depends_on_itself_via_optional_field.zig-2| ... | ... | @@ -11,7 +11,5 @@ export fn entry() void { |
| 11 | 11 | } |
| 12 | 12 | |
| 13 | 13 | // error |
| 14 | // backend=stage2 | |
| 15 | // target=native | |
| 16 | 14 | // |
| 17 | 15 | // :1:17: error: struct 'tmp.LhsExpr' depends on itself |
test/cases/compile_errors/struct_duplicate_field_name.zig-1| ... | ... | @@ -9,7 +9,6 @@ export fn entry() void { |
| 9 | 9 | } |
| 10 | 10 | |
| 11 | 11 | // error |
| 12 | // target=native | |
| 13 | 12 | // |
| 14 | 13 | // :2:5: error: duplicate struct member name 'foo' |
| 15 | 14 | // :3:5: note: duplicate name here |
test/cases/compile_errors/struct_init_passed_to_type_param.zig-2| ... | ... | @@ -7,8 +7,6 @@ fn hi(comptime T: type) usize { |
| 7 | 7 | export const value = hi(MyStruct{ .x = 12 }); |
| 8 | 8 | |
| 9 | 9 | // error |
| 10 | // backend=stage2 | |
| 11 | // target=native | |
| 12 | 10 | // |
| 13 | 11 | // :7:33: error: expected type 'type', found 'tmp.MyStruct' |
| 14 | 12 | // :1:18: note: struct declared here |
test/cases/compile_errors/struct_init_syntax_for_array.zig-2| ... | ... | @@ -4,7 +4,5 @@ comptime { |
| 4 | 4 | } |
| 5 | 5 | |
| 6 | 6 | // error |
| 7 | // backend=stage2 | |
| 8 | // target=native | |
| 9 | 7 | // |
| 10 | 8 | // :1:13: error: initializing array with struct syntax |
test/cases/compile_errors/struct_type_mismatch_in_arg.zig-2| ... | ... | @@ -9,8 +9,6 @@ comptime { |
| 9 | 9 | } |
| 10 | 10 | |
| 11 | 11 | // error |
| 12 | // backend=stage2 | |
| 13 | // target=native | |
| 14 | 12 | // |
| 15 | 13 | // :7:15: error: expected type 'tmp.Foo', found 'tmp.Bar' |
| 16 | 14 | // :2:13: note: struct declared here |
test/cases/compile_errors/struct_type_returned_from_non-generic_function.zig-2| ... | ... | @@ -3,8 +3,6 @@ pub export fn entry(param: usize) usize { |
| 3 | 3 | } |
| 4 | 4 | |
| 5 | 5 | // error |
| 6 | // backend=stage2 | |
| 7 | // target=native | |
| 8 | 6 | // |
| 9 | 7 | // :2:12: error: expected type 'usize', found 'type' |
| 10 | 8 | // :1:35: note: function return type declared here |
test/cases/compile_errors/struct_with_declarations_unavailable_for_reify_type.zig-2| ... | ... | @@ -5,7 +5,5 @@ export fn entry() void { |
| 5 | 5 | } |
| 6 | 6 | |
| 7 | 7 | // error |
| 8 | // backend=stage2 | |
| 9 | // target=native | |
| 10 | 8 | // |
| 11 | 9 | // :2:9: error: reified structs must have no decls |
test/cases/compile_errors/struct_with_invalid_field.zig-2| ... | ... | @@ -24,7 +24,5 @@ export fn entry() void { |
| 24 | 24 | } |
| 25 | 25 | |
| 26 | 26 | // error |
| 27 | // backend=stage2 | |
| 28 | // target=native | |
| 29 | 27 | // |
| 30 | 28 | // :14:17: error: use of undeclared identifier 'HeaderValue' |
test/cases/compile_errors/sub_sat_on_undefined_value.zig-2| ... | ... | @@ -12,8 +12,6 @@ comptime { |
| 12 | 12 | } |
| 13 | 13 | |
| 14 | 14 | // error |
| 15 | // backend=stage2 | |
| 16 | // target=native | |
| 17 | 15 | // |
| 18 | 16 | // :6:5: error: found compile log statement |
| 19 | 17 | // |
test/cases/compile_errors/sub_wrap_on_undefined_value.zig-2| ... | ... | @@ -12,8 +12,6 @@ comptime { |
| 12 | 12 | } |
| 13 | 13 | |
| 14 | 14 | // error |
| 15 | // backend=stage2 | |
| 16 | // target=native | |
| 17 | 15 | // |
| 18 | 16 | // :6:5: error: found compile log statement |
| 19 | 17 | // |
test/cases/compile_errors/switch_capture_incompatible_types.zig-2| ... | ... | @@ -15,8 +15,6 @@ export fn g() void { |
| 15 | 15 | } |
| 16 | 16 | |
| 17 | 17 | // error |
| 18 | // backend=stage2 | |
| 19 | // target=native | |
| 20 | 18 | // |
| 21 | 19 | // :5:20: error: capture group with incompatible types |
| 22 | 20 | // :5:20: note: incompatible types: 'u32' and '*u8' |
test/cases/compile_errors/switch_expression-duplicate_enumeration_prong.zig-2| ... | ... | @@ -19,8 +19,6 @@ export fn entry() usize { |
| 19 | 19 | } |
| 20 | 20 | |
| 21 | 21 | // error |
| 22 | // backend=stage2 | |
| 23 | // target=native | |
| 24 | 22 | // |
| 25 | 23 | // :13:15: error: duplicate switch value |
| 26 | 24 | // :10:15: note: previous value here |
test/cases/compile_errors/switch_expression-duplicate_enumeration_prong_when_else_present.zig-2| ... | ... | @@ -20,8 +20,6 @@ export fn entry() usize { |
| 20 | 20 | } |
| 21 | 21 | |
| 22 | 22 | // error |
| 23 | // backend=stage2 | |
| 24 | // target=native | |
| 25 | 23 | // |
| 26 | 24 | // :13:15: error: duplicate switch value |
| 27 | 25 | // :10:15: note: previous value here |
test/cases/compile_errors/switch_expression-duplicate_error_prong.zig-2| ... | ... | @@ -24,8 +24,6 @@ export fn entry() usize { |
| 24 | 24 | } |
| 25 | 25 | |
| 26 | 26 | // error |
| 27 | // backend=stage2 | |
| 28 | // target=native | |
| 29 | 27 | // |
| 30 | 28 | // :8:9: error: duplicate switch value |
| 31 | 29 | // :5:9: note: previous value here |
test/cases/compile_errors/switch_expression-duplicate_error_prong_when_else_present.zig-2| ... | ... | @@ -26,8 +26,6 @@ export fn entry() usize { |
| 26 | 26 | } |
| 27 | 27 | |
| 28 | 28 | // error |
| 29 | // backend=stage2 | |
| 30 | // target=native | |
| 31 | 29 | // |
| 32 | 30 | // :8:9: error: duplicate switch value |
| 33 | 31 | // :5:9: note: previous value here |
test/cases/compile_errors/switch_expression-duplicate_or_overlapping_integer_value.zig-2| ... | ... | @@ -11,8 +11,6 @@ export fn entry() usize { |
| 11 | 11 | } |
| 12 | 12 | |
| 13 | 13 | // error |
| 14 | // backend=stage2 | |
| 15 | // target=native | |
| 16 | 14 | // |
| 17 | 15 | // :6:12: error: duplicate switch value |
| 18 | 16 | // :5:17: note: previous value here |
test/cases/compile_errors/switch_expression-duplicate_type.zig-2| ... | ... | @@ -12,8 +12,6 @@ export fn entry() usize { |
| 12 | 12 | } |
| 13 | 13 | |
| 14 | 14 | // error |
| 15 | // backend=stage2 | |
| 16 | // target=native | |
| 17 | 15 | // |
| 18 | 16 | // :6:9: error: duplicate switch value |
| 19 | 17 | // :4:9: note: previous value here |
test/cases/compile_errors/switch_expression-duplicate_type_struct_alias.zig-2| ... | ... | @@ -16,8 +16,6 @@ export fn entry() usize { |
| 16 | 16 | } |
| 17 | 17 | |
| 18 | 18 | // error |
| 19 | // backend=stage2 | |
| 20 | // target=native | |
| 21 | 19 | // |
| 22 | 20 | // :10:9: error: duplicate switch value |
| 23 | 21 | // :8:9: note: previous value here |
test/cases/compile_errors/switch_expression-missing_enumeration_prong.zig-2| ... | ... | @@ -17,8 +17,6 @@ export fn entry() usize { |
| 17 | 17 | } |
| 18 | 18 | |
| 19 | 19 | // error |
| 20 | // backend=stage2 | |
| 21 | // target=native | |
| 22 | 20 | // |
| 23 | 21 | // :8:5: error: switch must handle all possibilities |
| 24 | 22 | // :5:5: note: unhandled enumeration value: 'Four' |
test/cases/compile_errors/switch_expression-missing_error_prong.zig-2| ... | ... | @@ -24,8 +24,6 @@ export fn entry() usize { |
| 24 | 24 | } |
| 25 | 25 | |
| 26 | 26 | // error |
| 27 | // backend=stage2 | |
| 28 | // target=native | |
| 29 | 27 | // |
| 30 | 28 | // :8:27: error: switch must handle all possibilities |
| 31 | 29 | // :8:27: note: unhandled error value: 'error.Four' |
test/cases/compile_errors/switch_expression-multiple_else_prongs.zig-2| ... | ... | @@ -26,8 +26,6 @@ export fn entry() void { |
| 26 | 26 | } |
| 27 | 27 | |
| 28 | 28 | // error |
| 29 | // backend=stage2 | |
| 30 | // target=native | |
| 31 | 29 | // |
| 32 | 30 | // :5:9: error: multiple else prongs in switch expression |
| 33 | 31 | // :4:9: note: previous else prong here |
test/cases/compile_errors/switch_expression-non_exhaustive_integer_prongs.zig-2| ... | ... | @@ -8,7 +8,5 @@ export fn entry() usize { |
| 8 | 8 | } |
| 9 | 9 | |
| 10 | 10 | // error |
| 11 | // backend=stage2 | |
| 12 | // target=native | |
| 13 | 11 | // |
| 14 | 12 | // :2:5: error: switch must handle all possibilities |
test/cases/compile_errors/switch_expression-switch_on_pointer_type_with_no_else.zig-2| ... | ... | @@ -9,7 +9,5 @@ export fn entry() usize { |
| 9 | 9 | } |
| 10 | 10 | |
| 11 | 11 | // error |
| 12 | // backend=stage2 | |
| 13 | // target=native | |
| 14 | 12 | // |
| 15 | 13 | // :2:5: error: else prong required when switching on type '*u8' |
test/cases/compile_errors/switch_expression-unreachable_else_prong_bool.zig-2| ... | ... | @@ -10,7 +10,5 @@ export fn entry() usize { |
| 10 | 10 | } |
| 11 | 11 | |
| 12 | 12 | // error |
| 13 | // backend=stage2 | |
| 14 | // target=native | |
| 15 | 13 | // |
| 16 | 14 | // :5:14: error: unreachable else prong; all cases already handled |
test/cases/compile_errors/switch_expression-unreachable_else_prong_enum.zig-2| ... | ... | @@ -20,7 +20,5 @@ export fn entry() usize { |
| 20 | 20 | } |
| 21 | 21 | |
| 22 | 22 | // error |
| 23 | // backend=stage2 | |
| 24 | // target=native | |
| 25 | 23 | // |
| 26 | 24 | // :14:14: error: unreachable else prong; all cases already handled |
test/cases/compile_errors/switch_expression-unreachable_else_prong_error.zig-2| ... | ... | @@ -25,8 +25,6 @@ export fn entry() usize { |
| 25 | 25 | } |
| 26 | 26 | |
| 27 | 27 | // error |
| 28 | // backend=stage2 | |
| 29 | // target=native | |
| 30 | 28 | // |
| 31 | 29 | // :7:14: error: unreachable else prong; all cases already handled |
| 32 | 30 | // :17:14: error: unreachable else prong; all cases already handled |
test/cases/compile_errors/switch_expression-unreachable_else_prong_range_i8.zig-2| ... | ... | @@ -13,7 +13,5 @@ export fn entry() usize { |
| 13 | 13 | } |
| 14 | 14 | |
| 15 | 15 | // error |
| 16 | // backend=stage2 | |
| 17 | // target=native | |
| 18 | 16 | // |
| 19 | 17 | // :8:14: error: unreachable else prong; all cases already handled |
test/cases/compile_errors/switch_expression-unreachable_else_prong_range_u8.zig-2| ... | ... | @@ -13,7 +13,5 @@ export fn entry() usize { |
| 13 | 13 | } |
| 14 | 14 | |
| 15 | 15 | // error |
| 16 | // backend=stage2 | |
| 17 | // target=native | |
| 18 | 16 | // |
| 19 | 17 | // :8:14: error: unreachable else prong; all cases already handled |
test/cases/compile_errors/switch_expression-unreachable_else_prong_u1.zig-2| ... | ... | @@ -10,7 +10,5 @@ export fn entry() usize { |
| 10 | 10 | } |
| 11 | 11 | |
| 12 | 12 | // error |
| 13 | // backend=stage2 | |
| 14 | // target=native | |
| 15 | 13 | // |
| 16 | 14 | // :5:14: error: unreachable else prong; all cases already handled |
test/cases/compile_errors/switch_expression-unreachable_else_prong_u2.zig-2| ... | ... | @@ -12,7 +12,5 @@ export fn entry() usize { |
| 12 | 12 | } |
| 13 | 13 | |
| 14 | 14 | // error |
| 15 | // backend=stage2 | |
| 16 | // target=native | |
| 17 | 15 | // |
| 18 | 16 | // :7:14: error: unreachable else prong; all cases already handled |
test/cases/compile_errors/switch_on_enum_with_1_field_with_no_prongs.zig-2| ... | ... | @@ -6,8 +6,6 @@ export fn entry() void { |
| 6 | 6 | } |
| 7 | 7 | |
| 8 | 8 | // error |
| 9 | // backend=stage2 | |
| 10 | // target=native | |
| 11 | 9 | // |
| 12 | 10 | // :5:5: error: switch must handle all possibilities |
| 13 | 11 | // :1:20: note: unhandled enumeration value: 'M' |
test/cases/compile_errors/switch_on_error_with_1_field_with_no_prongs.zig-2| ... | ... | @@ -11,8 +11,6 @@ export fn entry2() void { |
| 11 | 11 | } |
| 12 | 12 | |
| 13 | 13 | // error |
| 14 | // backend=stage2 | |
| 15 | // target=native | |
| 16 | 14 | // |
| 17 | 15 | // :5:24: error: switch must handle all possibilities |
| 18 | 16 | // :5:24: note: unhandled error value: 'error.M' |
test/cases/compile_errors/switch_on_error_with_capture_by_reference.zig-2| ... | ... | @@ -17,8 +17,6 @@ comptime { |
| 17 | 17 | } |
| 18 | 18 | |
| 19 | 19 | // error |
| 20 | // backend=stage2 | |
| 21 | // target=native | |
| 22 | 20 | // |
| 23 | 21 | // :4:24: error: error set cannot be captured by reference |
| 24 | 22 | // :13:24: error: error set cannot be captured by reference |
test/cases/compile_errors/switch_on_error_with_non_trivial_switch_operand.zig-2| ... | ... | @@ -15,8 +15,6 @@ export fn entry2() void { |
| 15 | 15 | } |
| 16 | 16 | |
| 17 | 17 | // error |
| 18 | // backend=stage2 | |
| 19 | // target=native | |
| 20 | 18 | // |
| 21 | 19 | // :4:42: error: invalid operands to binary expression: 'error_set' and 'comptime_int' |
| 22 | 20 | // :12:35: error: invalid operands to binary expression: 'error_set' and 'comptime_int' |
test/cases/compile_errors/switch_on_non_err_union.zig-1| ... | ... | @@ -5,7 +5,6 @@ pub fn main() void { |
| 5 | 5 | } |
| 6 | 6 | |
| 7 | 7 | // error |
| 8 | // backend=stage2 | |
| 9 | 8 | // target=x86_64-linux |
| 10 | 9 | // |
| 11 | 10 | // :2:23: error: expected error union type, found 'bool' |
test/cases/compile_errors/switch_on_slice.zig-2| ... | ... | @@ -8,7 +8,5 @@ pub export fn entry() void { |
| 8 | 8 | } |
| 9 | 9 | |
| 10 | 10 | // error |
| 11 | // backend=stage2 | |
| 12 | // target=native | |
| 13 | 11 | // |
| 14 | 12 | // :4:13: error: switch on type '[:0]const u8' |
test/cases/compile_errors/switch_on_union_with_no_attached_enum.zig-2| ... | ... | @@ -15,8 +15,6 @@ fn foo(a: *const Payload) void { |
| 15 | 15 | } |
| 16 | 16 | |
| 17 | 17 | // error |
| 18 | // backend=stage2 | |
| 19 | // target=native | |
| 20 | 18 | // |
| 21 | 19 | // :11:14: error: switch on union with no attached enum |
| 22 | 20 | // :1:17: note: consider 'union(enum)' here |
test/cases/compile_errors/switch_ranges_endpoints_are_validated.zig-2| ... | ... | @@ -14,8 +14,6 @@ pub export fn entr2() void { |
| 14 | 14 | } |
| 15 | 15 | |
| 16 | 16 | // error |
| 17 | // backend=stage2 | |
| 18 | // target=native | |
| 19 | 17 | // |
| 20 | 18 | // :4:10: error: range start value is greater than the end value |
| 21 | 19 | // :11:11: error: range start value is greater than the end value |
test/cases/compile_errors/switch_with_overlapping_case_ranges.zig-2| ... | ... | @@ -7,8 +7,6 @@ export fn entry() void { |
| 7 | 7 | } |
| 8 | 8 | |
| 9 | 9 | // error |
| 10 | // backend=stage2 | |
| 11 | // target=native | |
| 12 | 10 | // |
| 13 | 11 | // :5:10: error: duplicate switch value |
| 14 | 12 | // :4:10: note: previous value here |
test/cases/compile_errors/switching_with_exhaustive_enum_has___prong_.zig-2| ... | ... | @@ -12,8 +12,6 @@ pub export fn entry() void { |
| 12 | 12 | } |
| 13 | 13 | |
| 14 | 14 | // error |
| 15 | // backend=stage2 | |
| 16 | // target=native | |
| 17 | 15 | // |
| 18 | 16 | // :7:5: error: '_' prong only allowed when switching on non-exhaustive enums |
| 19 | 17 | // :10:9: note: '_' prong here |
test/cases/compile_errors/switching_with_non-exhaustive_enums.zig-2| ... | ... | @@ -31,8 +31,6 @@ pub export fn entry3() void { |
| 31 | 31 | } |
| 32 | 32 | |
| 33 | 33 | // error |
| 34 | // backend=stage2 | |
| 35 | // target=native | |
| 36 | 34 | // |
| 37 | 35 | // :12:5: error: switch must handle all possibilities |
| 38 | 36 | // :3:5: note: unhandled enumeration value: 'b' |
test/cases/compile_errors/tab_inside_comment.zig-2| ... | ... | @@ -2,7 +2,5 @@ |
| 2 | 2 | export fn entry() void {} |
| 3 | 3 | |
| 4 | 4 | // error |
| 5 | // backend=stage2 | |
| 6 | // target=native | |
| 7 | 5 | // |
| 8 | 6 | // :1:8: error: comment contains invalid byte: '\t' |
test/cases/compile_errors/tab_inside_doc_comment.zig-2| ... | ... | @@ -2,7 +2,5 @@ |
| 2 | 2 | export fn entry() void {} |
| 3 | 3 | |
| 4 | 4 | // error |
| 5 | // backend=stage2 | |
| 6 | // target=native | |
| 7 | 5 | // |
| 8 | 6 | // :1:13: error: comment contains invalid byte: '\t' |
test/cases/compile_errors/tab_inside_multiline_string.zig-2| ... | ... | @@ -7,7 +7,5 @@ export fn entry() void { |
| 7 | 7 | _ = foo; |
| 8 | 8 | } |
| 9 | 9 | // error |
| 10 | // backend=stage2 | |
| 11 | // target=native | |
| 12 | 10 | // |
| 13 | 11 | // :4:11: error: string literal contains invalid byte: '\t' |
test/cases/compile_errors/tab_inside_string.zig-2| ... | ... | @@ -4,7 +4,5 @@ export fn entry() void { |
| 4 | 4 | } |
| 5 | 5 | |
| 6 | 6 | // error |
| 7 | // backend=stage2 | |
| 8 | // target=native | |
| 9 | 7 | // |
| 10 | 8 | // :2:18: error: string literal contains invalid byte: '\t' |
test/cases/compile_errors/tagName_on_invalid_value_of_non-exhaustive_enum.zig-2| ... | ... | @@ -4,8 +4,6 @@ test "enum" { |
| 4 | 4 | } |
| 5 | 5 | |
| 6 | 6 | // error |
| 7 | // backend=stage2 | |
| 8 | // target=native | |
| 9 | 7 | // is_test=true |
| 10 | 8 | // |
| 11 | 9 | // :3:9: error: no field with value '@enumFromInt(5)' in enum 'tmp.test.enum.E' |
test/cases/compile_errors/tagName_used_on_union_with_no_associated_enum_tag.zig-2| ... | ... | @@ -8,8 +8,6 @@ export fn entry() void { |
| 8 | 8 | } |
| 9 | 9 | |
| 10 | 10 | // error |
| 11 | // backend=stage2 | |
| 12 | // target=native | |
| 13 | 11 | // |
| 14 | 12 | // :7:9: error: union 'tmp.FloatInt' is untagged |
| 15 | 13 | // :1:25: note: union declared here |
test/cases/compile_errors/tag_capture_on_non_inline_prong.zig-2| ... | ... | @@ -8,7 +8,5 @@ pub export fn entry() void { |
| 8 | 8 | } |
| 9 | 9 | |
| 10 | 10 | // error |
| 11 | // backend=stage2 | |
| 12 | // target=native | |
| 13 | 11 | // |
| 14 | 12 | // :5:26: error: tag capture on non-inline prong |
test/cases/compile_errors/take_slice_of_invalid_dereference.zig-2| ... | ... | @@ -4,7 +4,5 @@ export fn entry() void { |
| 4 | 4 | } |
| 5 | 5 | |
| 6 | 6 | // error |
| 7 | // backend=stage2 | |
| 8 | // target=native | |
| 9 | 7 | // |
| 10 | 8 | // :2:18: error: cannot dereference non-pointer type 'comptime_int' |
test/cases/compile_errors/threadlocal_qualifier_on_const.zig-2| ... | ... | @@ -4,7 +4,5 @@ export fn entry() i32 { |
| 4 | 4 | } |
| 5 | 5 | |
| 6 | 6 | // error |
| 7 | // backend=stage2 | |
| 8 | // target=native | |
| 9 | 7 | // |
| 10 | 8 | // :1:1: error: threadlocal variable cannot be constant |
test/cases/compile_errors/too_big_packed_struct.zig-2| ... | ... | @@ -7,7 +7,5 @@ pub export fn entry() void { |
| 7 | 7 | } |
| 8 | 8 | |
| 9 | 9 | // error |
| 10 | // backend=stage2 | |
| 11 | // target=native | |
| 12 | 10 | // |
| 13 | 11 | // :2:22: error: size of packed struct '131070' exceeds maximum bit width of 65535 |
test/cases/compile_errors/top_level_decl_dependency_loop.zig-2| ... | ... | @@ -6,7 +6,5 @@ export fn entry() void { |
| 6 | 6 | } |
| 7 | 7 | |
| 8 | 8 | // error |
| 9 | // backend=stage2 | |
| 10 | // target=native | |
| 11 | 9 | // |
| 12 | 10 | // :1:1: error: dependency loop detected |
test/cases/compile_errors/truncate_sign_mismatch.zig-2| ... | ... | @@ -16,8 +16,6 @@ export fn entry4() u8 { |
| 16 | 16 | } |
| 17 | 17 | |
| 18 | 18 | // error |
| 19 | // backend=stage2 | |
| 20 | // target=native | |
| 21 | 19 | // |
| 22 | 20 | // :3:26: error: expected signed integer type, found 'u32' |
| 23 | 21 | // :7:26: error: expected unsigned integer type, found 'i32' |
test/cases/compile_errors/try_in_function_with_non_error_return_type.zig-2| ... | ... | @@ -4,8 +4,6 @@ export fn f() void { |
| 4 | 4 | fn something() anyerror!void {} |
| 5 | 5 | |
| 6 | 6 | // error |
| 7 | // backend=stage2 | |
| 8 | // target=native | |
| 9 | 7 | // |
| 10 | 8 | // :2:5: error: expected type 'void', found 'anyerror' |
| 11 | 9 | // :1:15: note: function cannot return an error |
test/cases/compile_errors/try_return.zig-2| ... | ... | @@ -4,8 +4,6 @@ pub fn foo() !void { |
| 4 | 4 | pub fn bar() !void {} |
| 5 | 5 | |
| 6 | 6 | // error |
| 7 | // backend=stage2 | |
| 8 | // target=native | |
| 9 | 7 | // |
| 10 | 8 | // :2:5: error: unreachable code |
| 11 | 9 | // :2:9: note: control flow is diverted here |
test/cases/compile_errors/tuple_declarations.zig-2| ... | ... | @@ -16,8 +16,6 @@ const T = struct { |
| 16 | 16 | }; |
| 17 | 17 | |
| 18 | 18 | // error |
| 19 | // backend=stage2 | |
| 20 | // target=native | |
| 21 | 19 | // |
| 22 | 20 | // :2:5: error: enum field missing name |
| 23 | 21 | // :5:5: error: union field missing name |
test/cases/compile_errors/tuple_init_edge_cases.zig-2| ... | ... | @@ -66,8 +66,6 @@ pub export fn entry6() void { |
| 66 | 66 | } |
| 67 | 67 | |
| 68 | 68 | // error |
| 69 | // backend=stage2 | |
| 70 | // target=native | |
| 71 | 69 | // |
| 72 | 70 | // :18:14: error: missing tuple field with index 1 |
| 73 | 71 | // :25:14: error: missing tuple field with index 1 |
test/cases/compile_errors/tuple_ptr_to_mut_slice.zig-2| ... | ... | @@ -19,8 +19,6 @@ export fn entry4() void { |
| 19 | 19 | } |
| 20 | 20 | |
| 21 | 21 | // error |
| 22 | // backend=stage2 | |
| 23 | // target=native | |
| 24 | 22 | // |
| 25 | 23 | // :3:19: error: cannot cast pointer to tuple to '[]u8' |
| 26 | 24 | // :3:19: note: pointers to tuples can only coerce to constant pointers |
test/cases/compile_errors/type_checking_function_pointers.zig-2| ... | ... | @@ -9,8 +9,6 @@ export fn entry() void { |
| 9 | 9 | } |
| 10 | 10 | |
| 11 | 11 | // error |
| 12 | // backend=stage2 | |
| 13 | // target=native | |
| 14 | 12 | // |
| 15 | 13 | // :8:7: error: expected type '*const fn (*const u8) void', found '*const fn (u8) void' |
| 16 | 14 | // :8:7: note: pointer type child 'fn (u8) void' cannot cast into pointer type child 'fn (*const u8) void' |
test/cases/compile_errors/type_error_in_implicit_return.zig-2| ... | ... | @@ -8,8 +8,6 @@ pub export fn entry() void { |
| 8 | 8 | } |
| 9 | 9 | |
| 10 | 10 | // error |
| 11 | // backend=stage2 | |
| 12 | // target=native | |
| 13 | 11 | // |
| 14 | 12 | // :1:16: error: function with non-void return type 'u32' implicitly returns |
| 15 | 13 | // :3:1: note: control flow reaches end of body here |
test/cases/compile_errors/type_mismatch_in_C_prototype_with_varargs.zig-2| ... | ... | @@ -7,8 +7,6 @@ export fn main() void { |
| 7 | 7 | } |
| 8 | 8 | |
| 9 | 9 | // error |
| 10 | // backend=stage2 | |
| 11 | // target=native | |
| 12 | 10 | // |
| 13 | 11 | // :5:22: error: expected type '?fn ([*c]u8, ...) callconv(.c) void', found 'fn ([*:0]u8, ...) callconv(.c) void' |
| 14 | 12 | // :5:22: note: parameter 0 '[*:0]u8' cannot cast into '[*c]u8' |
test/cases/compile_errors/type_mismatch_with_tuple_concatenation.zig-2| ... | ... | @@ -4,7 +4,5 @@ export fn entry() void { |
| 4 | 4 | } |
| 5 | 5 | |
| 6 | 6 | // error |
| 7 | // backend=stage2 | |
| 8 | // target=native | |
| 9 | 7 | // |
| 10 | 8 | // :3:11: error: expected type '@TypeOf(.{})', found 'struct { comptime comptime_int = 1, comptime comptime_int = 2, comptime comptime_int = 3 }' |
test/cases/compile_errors/type_variables_must_be_constant.zig-2| ... | ... | @@ -4,8 +4,6 @@ export fn entry() foo { |
| 4 | 4 | } |
| 5 | 5 | |
| 6 | 6 | // error |
| 7 | // backend=stage2 | |
| 8 | // target=native | |
| 9 | 7 | // |
| 10 | 8 | // :1:11: error: variable of type 'type' must be const or comptime |
| 11 | 9 | // :1:11: note: types are not available at runtime |
test/cases/compile_errors/undeclared_identifier.zig-2| ... | ... | @@ -3,7 +3,5 @@ export fn a() void { |
| 3 | 3 | } |
| 4 | 4 | |
| 5 | 5 | // error |
| 6 | // backend=stage2 | |
| 7 | // target=native | |
| 8 | 6 | // |
| 9 | 7 | // :2:12: error: use of undeclared identifier 'b' |
test/cases/compile_errors/undeclared_identifier_error_should_mark_fn_as_impure.zig-2| ... | ... | @@ -6,7 +6,5 @@ fn test_a_thing() void { |
| 6 | 6 | } |
| 7 | 7 | |
| 8 | 8 | // error |
| 9 | // backend=stage2 | |
| 10 | // target=native | |
| 11 | 9 | // |
| 12 | 10 | // :5:5: error: use of undeclared identifier 'bad_fn_call' |
test/cases/compile_errors/undeclared_identifier_in_unanalyzed_branch.zig-2| ... | ... | @@ -5,7 +5,5 @@ export fn a() void { |
| 5 | 5 | } |
| 6 | 6 | |
| 7 | 7 | // error |
| 8 | // backend=stage2 | |
| 9 | // target=native | |
| 10 | 8 | // |
| 11 | 9 | // :3:9: error: use of undeclared identifier 'lol_this_doesnt_exist' |
test/cases/compile_errors/undefined_function_call.zig-2| ... | ... | @@ -3,7 +3,5 @@ export fn a() void { |
| 3 | 3 | } |
| 4 | 4 | |
| 5 | 5 | // error |
| 6 | // backend=stage2 | |
| 7 | // target=native | |
| 8 | 6 | // |
| 9 | 7 | // :2:5: error: use of undeclared identifier 'b' |
test/cases/compile_errors/underscore_is_not_a_declarable_symbol.zig-2| ... | ... | @@ -4,7 +4,5 @@ export fn f1() usize { |
| 4 | 4 | } |
| 5 | 5 | |
| 6 | 6 | // error |
| 7 | // backend=stage2 | |
| 8 | // target=native | |
| 9 | 7 | // |
| 10 | 8 | // :2:9: error: '_' used as an identifier without @"_" syntax |
test/cases/compile_errors/underscore_should_not_be_usable_inside_for.zig-2| ... | ... | @@ -7,7 +7,5 @@ export fn returns() void { |
| 7 | 7 | } |
| 8 | 8 | |
| 9 | 9 | // error |
| 10 | // backend=stage2 | |
| 11 | // target=native | |
| 12 | 10 | // |
| 13 | 11 | // :4:20: error: '_' used as an identifier without @"_" syntax |
test/cases/compile_errors/underscore_should_not_be_usable_inside_while.zig-2| ... | ... | @@ -10,7 +10,5 @@ fn optionalReturn() ?u32 { |
| 10 | 10 | } |
| 11 | 11 | |
| 12 | 12 | // error |
| 13 | // backend=stage2 | |
| 14 | // target=native | |
| 15 | 13 | // |
| 16 | 14 | // :4:20: error: '_' used as an identifier without @"_" syntax |
test/cases/compile_errors/underscore_should_not_be_usable_inside_while_else.zig-2| ... | ... | @@ -12,7 +12,5 @@ fn optionalReturnError() !?u32 { |
| 12 | 12 | } |
| 13 | 13 | |
| 14 | 14 | // error |
| 15 | // backend=stage2 | |
| 16 | // target=native | |
| 17 | 15 | // |
| 18 | 16 | // :6:17: error: '_' used as an identifier without @"_" syntax |
test/cases/compile_errors/unhandled_enum_value_in_switch_with_enum_declared_in_other_file.zig-2| ... | ... | @@ -6,8 +6,6 @@ pub export fn entry1() void { |
| 6 | 6 | } |
| 7 | 7 | |
| 8 | 8 | // error |
| 9 | // backend=stage2 | |
| 10 | // target=native | |
| 11 | 9 | // |
| 12 | 10 | // :5:5: error: switch must handle all possibilities |
| 13 | 11 | // :?:?: note: unhandled enumeration value: 'gt' |
test/cases/compile_errors/union_access_of_inactive_field.zig-1| ... | ... | @@ -10,7 +10,6 @@ comptime { |
| 10 | 10 | } |
| 11 | 11 | |
| 12 | 12 | // error |
| 13 | // target=native | |
| 14 | 13 | // |
| 15 | 14 | // :7:16: error: access of union field 'b' while field 'a' is active |
| 16 | 15 | // :1:11: note: union declared here |
test/cases/compile_errors/union_auto-enum_value_already_taken.zig-2| ... | ... | @@ -11,8 +11,6 @@ export fn entry() void { |
| 11 | 11 | } |
| 12 | 12 | |
| 13 | 13 | // error |
| 14 | // backend=stage2 | |
| 15 | // target=native | |
| 16 | 14 | // |
| 17 | 15 | // :6:9: error: enum tag value 60 already taken |
| 18 | 16 | // :4:9: note: other occurrence here |
test/cases/compile_errors/union_calling_inactive_field_as_fn.zig-2| ... | ... | @@ -9,8 +9,6 @@ export fn entry() void { |
| 9 | 9 | } |
| 10 | 10 | |
| 11 | 11 | // error |
| 12 | // backend=stage2 | |
| 13 | // target=native | |
| 14 | 12 | // |
| 15 | 13 | // :8:10: error: access of union field 'float' while field 'int' is active |
| 16 | 14 | // :1:11: note: union declared here |
test/cases/compile_errors/union_duplicate_enum_field.zig-1| ... | ... | @@ -10,7 +10,6 @@ export fn foo() void { |
| 10 | 10 | } |
| 11 | 11 | |
| 12 | 12 | // error |
| 13 | // target=native | |
| 14 | 13 | // |
| 15 | 14 | // :3:5: error: duplicate union member name 'a' |
| 16 | 15 | // :4:5: note: duplicate name here |
test/cases/compile_errors/union_duplicate_field_definition.zig-1| ... | ... | @@ -9,7 +9,6 @@ export fn entry() void { |
| 9 | 9 | } |
| 10 | 10 | |
| 11 | 11 | // error |
| 12 | // target=native | |
| 13 | 12 | // |
| 14 | 13 | // :2:5: error: duplicate union member name 'foo' |
| 15 | 14 | // :3:5: note: duplicate name here |
test/cases/compile_errors/union_enum_field_does_not_match_enum.zig-2| ... | ... | @@ -15,8 +15,6 @@ export fn entry() void { |
| 15 | 15 | } |
| 16 | 16 | |
| 17 | 17 | // error |
| 18 | // backend=stage2 | |
| 19 | // target=native | |
| 20 | 18 | // |
| 21 | 19 | // :10:5: error: no field named 'D' in enum 'tmp.Letter' |
| 22 | 20 | // :1:16: note: enum declared here |
test/cases/compile_errors/union_enum_field_missing.zig-1| ... | ... | @@ -14,7 +14,6 @@ export fn entry() usize { |
| 14 | 14 | } |
| 15 | 15 | |
| 16 | 16 | // error |
| 17 | // target=native | |
| 18 | 17 | // |
| 19 | 18 | // :7:11: error: enum field(s) missing in union |
| 20 | 19 | // :4:5: note: field 'c' missing, declared here |
test/cases/compile_errors/union_extra_field.zig-1| ... | ... | @@ -14,7 +14,6 @@ export fn entry() usize { |
| 14 | 14 | } |
| 15 | 15 | |
| 16 | 16 | // error |
| 17 | // target=native | |
| 18 | 17 | // |
| 19 | 18 | // :10:5: error: no field named 'd' in enum 'tmp.E' |
| 20 | 19 | // :1:11: note: enum declared here |
test/cases/compile_errors/union_fields_are_resolved_before_tag_type_is_needed.zig-2| ... | ... | @@ -9,8 +9,6 @@ pub export fn entry() void { |
| 9 | 9 | } |
| 10 | 10 | |
| 11 | 11 | // error |
| 12 | // backend=stage2 | |
| 13 | // target=native | |
| 14 | 12 | // |
| 15 | 13 | // :8:8: error: no field or member function named 'f' in '@typeInfo(tmp.T).@"union".tag_type.?' |
| 16 | 14 | // :1:11: note: enum declared here |
test/cases/compile_errors/union_init_with_non_type_as_first_param.zig-2| ... | ... | @@ -3,7 +3,5 @@ export fn u() void { |
| 3 | 3 | } |
| 4 | 4 | |
| 5 | 5 | // error |
| 6 | // backend=stage2 | |
| 7 | // target=native | |
| 8 | 6 | // |
| 9 | 7 | // :2:20: error: expected type 'type', found 'comptime_int' |
test/cases/compile_errors/union_init_with_none_or_multiple_fields.zig-2| ... | ... | @@ -24,8 +24,6 @@ export fn u2m() void { |
| 24 | 24 | } |
| 25 | 25 | |
| 26 | 26 | // error |
| 27 | // backend=stage2 | |
| 28 | // target=native | |
| 29 | 27 | // |
| 30 | 28 | // :10:20: error: union initializer must initialize one field |
| 31 | 29 | // :14:20: error: cannot initialize multiple union fields at once; unions can only have one active field |
test/cases/compile_errors/union_init_with_struct_as_first_param.zig-2| ... | ... | @@ -7,8 +7,6 @@ export fn u() void { |
| 7 | 7 | } |
| 8 | 8 | |
| 9 | 9 | // error |
| 10 | // backend=stage2 | |
| 11 | // target=native | |
| 12 | 10 | // |
| 13 | 11 | // :6:20: error: expected union type, found 'tmp.S' |
| 14 | 12 | // :1:11: note: struct declared here |
test/cases/compile_errors/union_noreturn_field_initialized.zig-2| ... | ... | @@ -29,8 +29,6 @@ pub export fn entry3() void { |
| 29 | 29 | } |
| 30 | 30 | |
| 31 | 31 | // error |
| 32 | // backend=stage2 | |
| 33 | // target=native | |
| 34 | 32 | // |
| 35 | 33 | // :11:14: error: cannot initialize 'noreturn' field of union |
| 36 | 34 | // :4:9: note: field 'b' declared here |
test/cases/compile_errors/union_runtime_coercion_from_enum.zig-1| ... | ... | @@ -15,7 +15,6 @@ export fn doTheTest() u64 { |
| 15 | 15 | } |
| 16 | 16 | |
| 17 | 17 | // error |
| 18 | // target=native | |
| 19 | 18 | // |
| 20 | 19 | // :13:19: error: runtime coercion from enum 'tmp.E' to union 'tmp.U' which has non-void fields |
| 21 | 20 | // :6:5: note: field 'a' has type 'u32' |
test/cases/compile_errors/union_with_specified_enum_omits_field.zig-2| ... | ... | @@ -12,8 +12,6 @@ export fn entry() usize { |
| 12 | 12 | } |
| 13 | 13 | |
| 14 | 14 | // error |
| 15 | // backend=stage2 | |
| 16 | // target=native | |
| 17 | 15 | // |
| 18 | 16 | // :6:17: error: enum field(s) missing in union |
| 19 | 17 | // :4:5: note: field 'C' missing, declared here |
test/cases/compile_errors/union_with_too_small_explicit_signed_tag_type.zig-2| ... | ... | @@ -9,8 +9,6 @@ export fn entry() void { |
| 9 | 9 | } |
| 10 | 10 | |
| 11 | 11 | // error |
| 12 | // backend=stage2 | |
| 13 | // target=native | |
| 14 | 12 | // |
| 15 | 13 | // :1:22: error: specified integer tag type cannot represent every field |
| 16 | 14 | // :1:22: note: type 'i2' cannot fit values in range 0...3 |
test/cases/compile_errors/union_with_too_small_explicit_unsigned_tag_type.zig-2| ... | ... | @@ -10,8 +10,6 @@ export fn entry() void { |
| 10 | 10 | } |
| 11 | 11 | |
| 12 | 12 | // error |
| 13 | // backend=stage2 | |
| 14 | // target=native | |
| 15 | 13 | // |
| 16 | 14 | // :1:22: error: specified integer tag type cannot represent every field |
| 17 | 15 | // :1:22: note: type 'u2' cannot fit values in range 0...4 |
test/cases/compile_errors/unknown_length_pointer_to_opaque.zig-2| ... | ... | @@ -1,7 +1,5 @@ |
| 1 | 1 | export const T = [*]opaque {}; |
| 2 | 2 | |
| 3 | 3 | // error |
| 4 | // backend=stage2 | |
| 5 | // target=native | |
| 6 | 4 | // |
| 7 | 5 | // :1:21: error: unknown-length pointer to opaque not allowed |
test/cases/compile_errors/unreachable_code-double_break.zig-2| ... | ... | @@ -6,8 +6,6 @@ export fn a() void { |
| 6 | 6 | } |
| 7 | 7 | |
| 8 | 8 | // error |
| 9 | // backend=stage2 | |
| 10 | // target=native | |
| 11 | 9 | // |
| 12 | 10 | // :3:9: error: unreachable code |
| 13 | 11 | // :3:20: note: control flow is diverted here |
test/cases/compile_errors/unreachable_code-nested_returns.zig-2| ... | ... | @@ -3,8 +3,6 @@ export fn a() i32 { |
| 3 | 3 | } |
| 4 | 4 | |
| 5 | 5 | // error |
| 6 | // backend=stage2 | |
| 7 | // target=native | |
| 8 | 6 | // |
| 9 | 7 | // :2:5: error: unreachable code |
| 10 | 8 | // :2:12: note: control flow is diverted here |
test/cases/compile_errors/unreachable_code.zig-2| ... | ... | @@ -6,8 +6,6 @@ export fn a() void { |
| 6 | 6 | fn b() void {} |
| 7 | 7 | |
| 8 | 8 | // error |
| 9 | // backend=stage2 | |
| 10 | // target=native | |
| 11 | 9 | // |
| 12 | 10 | // :3:6: error: unreachable code |
| 13 | 11 | // :2:5: note: control flow is diverted here |
test/cases/compile_errors/unreachable_else_prong_err_set.zig-2| ... | ... | @@ -21,7 +21,5 @@ pub export fn simple() void { |
| 21 | 21 | } |
| 22 | 22 | |
| 23 | 23 | // error |
| 24 | // backend=stage2 | |
| 25 | // target=native | |
| 26 | 24 | // |
| 27 | 25 | // :7:14: error: unreachable else prong; all cases already handled |
test/cases/compile_errors/unreachable_in_naked_func.zig-2| ... | ... | @@ -19,8 +19,6 @@ comptime { |
| 19 | 19 | } |
| 20 | 20 | |
| 21 | 21 | // error |
| 22 | // backend=stage2 | |
| 23 | // target=native | |
| 24 | 22 | // |
| 25 | 23 | // :2:5: error: runtime safety check not allowed in naked function |
| 26 | 24 | // :2:5: note: use @setRuntimeSafety to disable runtime safety |
test/cases/compile_errors/unreachable_parameter.zig-2| ... | ... | @@ -6,7 +6,5 @@ export fn entry() void { |
| 6 | 6 | } |
| 7 | 7 | |
| 8 | 8 | // error |
| 9 | // backend=stage2 | |
| 10 | // target=native | |
| 11 | 9 | // |
| 12 | 10 | // :1:6: error: parameter of type 'noreturn' not allowed |
test/cases/compile_errors/unreachable_variable.zig-2| ... | ... | @@ -4,7 +4,5 @@ export fn f() void { |
| 4 | 4 | } |
| 5 | 5 | |
| 6 | 6 | // error |
| 7 | // backend=stage2 | |
| 8 | // target=native | |
| 9 | 7 | // |
| 10 | 8 | // :2:25: error: cannot cast to noreturn |
test/cases/compile_errors/unreachable_with_return.zig-2| ... | ... | @@ -6,8 +6,6 @@ export fn entry() void { |
| 6 | 6 | } |
| 7 | 7 | |
| 8 | 8 | // error |
| 9 | // backend=stage2 | |
| 10 | // target=native | |
| 11 | 9 | // |
| 12 | 10 | // :2:5: error: function declared 'noreturn' returns |
| 13 | 11 | // :1:8: note: 'noreturn' declared here |
test/cases/compile_errors/untagged_union_integer_conversion.zig-2| ... | ... | @@ -4,8 +4,6 @@ comptime { |
| 4 | 4 | } |
| 5 | 5 | |
| 6 | 6 | // error |
| 7 | // backend=stage2 | |
| 8 | // target=native | |
| 9 | 7 | // |
| 10 | 8 | // :3:18: error: untagged union 'tmp.UntaggedUnion' cannot be converted to integer |
| 11 | 9 | // :1:23: note: union declared here |
test/cases/compile_errors/unused_value_in_switch_in_loop.zig-2| ... | ... | @@ -8,8 +8,6 @@ export fn entry() void { |
| 8 | 8 | } |
| 9 | 9 | |
| 10 | 10 | // error |
| 11 | // backend=stage2 | |
| 12 | // target=native | |
| 13 | 11 | // |
| 14 | 12 | // :3:18: error: incompatible types: 'comptime_int' and 'void' |
| 15 | 13 | // :4:14: note: type 'comptime_int' here |
test/cases/compile_errors/unused_variable_error_on_errdefer.zig-2| ... | ... | @@ -7,7 +7,5 @@ export fn entry() void { |
| 7 | 7 | } |
| 8 | 8 | |
| 9 | 9 | // error |
| 10 | // backend=stage2 | |
| 11 | // target=native | |
| 12 | 10 | // |
| 13 | 11 | // :2:15: error: unused capture |
test/cases/compile_errors/use_anyopaque_as_return_type_of_fn_ptr.zig-2| ... | ... | @@ -4,7 +4,5 @@ export fn entry() void { |
| 4 | 4 | } |
| 5 | 5 | |
| 6 | 6 | // error |
| 7 | // backend=stage2 | |
| 8 | // target=native | |
| 9 | 7 | // |
| 10 | 8 | // :2:20: error: opaque return type 'anyopaque' not allowed |
test/cases/compile_errors/use_implicit_casts_to_assign_null_to_non-nullable_pointer.zig-2| ... | ... | @@ -7,8 +7,6 @@ export fn entry() void { |
| 7 | 7 | } |
| 8 | 8 | |
| 9 | 9 | // error |
| 10 | // backend=stage2 | |
| 11 | // target=native | |
| 12 | 10 | // |
| 13 | 11 | // :4:24: error: expected type '*?*i32', found '**i32' |
| 14 | 12 | // :4:24: note: pointer type child '*i32' cannot cast into pointer type child '?*i32' |
test/cases/compile_errors/use_invalid_number_literal_as_array_index.zig-2| ... | ... | @@ -5,8 +5,6 @@ export fn entry() void { |
| 5 | 5 | } |
| 6 | 6 | |
| 7 | 7 | // error |
| 8 | // backend=stage2 | |
| 9 | // target=native | |
| 10 | 8 | // |
| 11 | 9 | // :1:9: error: variable of type 'comptime_int' must be const or comptime |
| 12 | 10 | // :1:9: note: to modify this variable at runtime, it must be given an explicit fixed-size number type |
test/cases/compile_errors/use_of_undeclared_identifier.zig-2| ... | ... | @@ -3,7 +3,5 @@ export fn f() void { |
| 3 | 3 | } |
| 4 | 4 | |
| 5 | 5 | // error |
| 6 | // backend=stage2 | |
| 7 | // target=native | |
| 8 | 6 | // |
| 9 | 7 | // :2:5: error: use of undeclared identifier 'b' |
test/cases/compile_errors/using_an_unknown_len_ptr_type_instead_of_array.zig-2| ... | ... | @@ -7,7 +7,5 @@ comptime { |
| 7 | 7 | } |
| 8 | 8 | |
| 9 | 9 | // error |
| 10 | // backend=stage2 | |
| 11 | // target=native | |
| 12 | 10 | // |
| 13 | 11 | // :1:21: error: type '[*][*]const u8' does not support array initialization syntax |
test/cases/compile_errors/variable_has_wrong_type.zig-2| ... | ... | @@ -4,8 +4,6 @@ export fn f() i32 { |
| 4 | 4 | } |
| 5 | 5 | |
| 6 | 6 | // error |
| 7 | // backend=stage2 | |
| 8 | // target=native | |
| 9 | 7 | // |
| 10 | 8 | // :3:12: error: expected type 'i32', found '*const [1:0]u8' |
| 11 | 9 | // :1:15: note: function return type declared here |
test/cases/compile_errors/variable_initialization_compile_error_then_referenced.zig-2| ... | ... | @@ -13,7 +13,5 @@ export fn entry() void { |
| 13 | 13 | } |
| 14 | 14 | |
| 15 | 15 | // error |
| 16 | // backend=stage2 | |
| 17 | // target=native | |
| 18 | 16 | // |
| 19 | 17 | // :2:12: error: use of undeclared identifier 'T' |
test/cases/compile_errors/variable_with_type_noreturn.zig-2| ... | ... | @@ -4,8 +4,6 @@ export fn entry9() void { |
| 4 | 4 | } |
| 5 | 5 | |
| 6 | 6 | // error |
| 7 | // backend=stage2 | |
| 8 | // target=native | |
| 9 | 7 | // |
| 10 | 8 | // :2:5: error: unreachable code |
| 11 | 9 | // :2:23: note: control flow is diverted here |
test/cases/compile_errors/variadic_arg_validation.zig-2| ... | ... | @@ -19,8 +19,6 @@ pub export fn entry3() void { |
| 19 | 19 | } |
| 20 | 20 | |
| 21 | 21 | // error |
| 22 | // backend=stage2 | |
| 23 | // target=native | |
| 24 | 22 | // |
| 25 | 23 | // :4:33: error: integer and float literals passed to variadic function must be casted to a fixed-size number type |
| 26 | 24 | // :9:24: error: arrays must be passed by reference to variadic function |
test/cases/compile_errors/vector_index_out_of_bounds.zig-2| ... | ... | @@ -4,7 +4,5 @@ export fn entry() void { |
| 4 | 4 | } |
| 5 | 5 | |
| 6 | 6 | // error |
| 7 | // backend=stage2 | |
| 8 | // target=native | |
| 9 | 7 | // |
| 10 | 8 | // :2:30: error: expected 3 vector elements; found 4 |
test/cases/compile_errors/volatile_on_global_assembly.zig-2| ... | ... | @@ -3,7 +3,5 @@ comptime { |
| 3 | 3 | } |
| 4 | 4 | |
| 5 | 5 | // error |
| 6 | // backend=stage2 | |
| 7 | // target=native | |
| 8 | 6 | // |
| 9 | 7 | // :2:9: error: volatile is meaningless on global assembly |
test/cases/compile_errors/wasmMemoryGrow_is_a_compile_error_in_non-Wasm_targets.zig-1| ... | ... | @@ -4,7 +4,6 @@ export fn foo() void { |
| 4 | 4 | } |
| 5 | 5 | |
| 6 | 6 | // error |
| 7 | // backend=stage2 | |
| 8 | 7 | // target=x86_64-native |
| 9 | 8 | // |
| 10 | 9 | // :2:9: error: builtin @wasmMemoryGrow is available when targeting WebAssembly; targeted CPU architecture is x86_64 |
test/cases/compile_errors/wasmMemorySize_is_a_compile_error_in_non-Wasm_targets.zig-1| ... | ... | @@ -4,7 +4,6 @@ export fn foo() void { |
| 4 | 4 | } |
| 5 | 5 | |
| 6 | 6 | // error |
| 7 | // backend=stage2 | |
| 8 | 7 | // target=x86_64-native |
| 9 | 8 | // |
| 10 | 9 | // :2:9: error: builtin @wasmMemorySize is available when targeting WebAssembly; targeted CPU architecture is x86_64 |
test/cases/compile_errors/while_expected_bool_got_error_union.zig-2| ... | ... | @@ -6,7 +6,5 @@ fn bar() anyerror!i32 { |
| 6 | 6 | } |
| 7 | 7 | |
| 8 | 8 | // error |
| 9 | // backend=stage2 | |
| 10 | // target=native | |
| 11 | 9 | // |
| 12 | 10 | // :2:15: error: expected type 'bool', found 'anyerror!i32' |
test/cases/compile_errors/while_expected_bool_got_optional.zig-2| ... | ... | @@ -6,7 +6,5 @@ fn bar() ?i32 { |
| 6 | 6 | } |
| 7 | 7 | |
| 8 | 8 | // error |
| 9 | // backend=stage2 | |
| 10 | // target=native | |
| 11 | 9 | // |
| 12 | 10 | // :2:15: error: expected type 'bool', found '?i32' |
test/cases/compile_errors/while_expected_error_union_got_bool.zig-2| ... | ... | @@ -10,7 +10,5 @@ fn bar() bool { |
| 10 | 10 | } |
| 11 | 11 | |
| 12 | 12 | // error |
| 13 | // backend=stage2 | |
| 14 | // target=native | |
| 15 | 13 | // |
| 16 | 14 | // :2:15: error: expected error union type, found 'bool' |
test/cases/compile_errors/while_expected_error_union_got_optional.zig-2| ... | ... | @@ -10,7 +10,5 @@ fn bar() ?i32 { |
| 10 | 10 | } |
| 11 | 11 | |
| 12 | 12 | // error |
| 13 | // backend=stage2 | |
| 14 | // target=native | |
| 15 | 13 | // |
| 16 | 14 | // :2:15: error: expected error union type, found '?i32' |
test/cases/compile_errors/while_expected_optional_got_bool.zig-2| ... | ... | @@ -8,7 +8,5 @@ fn bar() bool { |
| 8 | 8 | } |
| 9 | 9 | |
| 10 | 10 | // error |
| 11 | // backend=stage2 | |
| 12 | // target=native | |
| 13 | 11 | // |
| 14 | 12 | // :2:15: error: expected optional type, found 'bool' |
test/cases/compile_errors/while_expected_optional_got_error_union.zig-2| ... | ... | @@ -8,8 +8,6 @@ fn bar() anyerror!i32 { |
| 8 | 8 | } |
| 9 | 9 | |
| 10 | 10 | // error |
| 11 | // backend=stage2 | |
| 12 | // target=native | |
| 13 | 11 | // |
| 14 | 12 | // :2:15: error: expected optional type, found 'anyerror!i32' |
| 15 | 13 | // :2:15: note: consider using 'try', 'catch', or 'if' |
test/cases/compile_errors/while_loop_body_expression_ignored.zig-2| ... | ... | @@ -27,8 +27,6 @@ export fn f5() void { |
| 27 | 27 | } |
| 28 | 28 | |
| 29 | 29 | // error |
| 30 | // backend=stage2 | |
| 31 | // target=native | |
| 32 | 30 | // |
| 33 | 31 | // :5:25: error: value of type 'usize' ignored |
| 34 | 32 | // :5:25: note: all non-void values must be used |
test/cases/compile_errors/while_loop_break_value_ignored.zig-2| ... | ... | @@ -21,8 +21,6 @@ export fn f2() void { |
| 21 | 21 | } |
| 22 | 22 | |
| 23 | 23 | // error |
| 24 | // backend=stage2 | |
| 25 | // target=native | |
| 26 | 24 | // |
| 27 | 25 | // :7:5: error: incompatible types: 'usize' and 'void' |
| 28 | 26 | // :8:22: note: type 'usize' here |
test/cases/compile_errors/write_to_const_global_variable.zig-2| ... | ... | @@ -7,7 +7,5 @@ export fn entry() void { |
| 7 | 7 | } |
| 8 | 8 | |
| 9 | 9 | // error |
| 10 | // backend=stage2 | |
| 11 | // target=native | |
| 12 | 10 | // |
| 13 | 11 | // :3:5: error: cannot assign to constant |
test/cases/compile_errors/wrong_function_type.zig-2| ... | ... | @@ -13,8 +13,6 @@ export fn entry() usize { |
| 13 | 13 | } |
| 14 | 14 | |
| 15 | 15 | // error |
| 16 | // backend=stage2 | |
| 17 | // target=native | |
| 18 | 16 | // |
| 19 | 17 | // :1:28: error: expected type 'fn () void', found 'fn () i32' |
| 20 | 18 | // :1:28: note: return type 'i32' cannot cast into return type 'void' |
test/cases/compile_errors/wrong_number_of_arguments.zig-2| ... | ... | @@ -8,8 +8,6 @@ fn c(d: i32, e: i32, f: i32) void { |
| 8 | 8 | } |
| 9 | 9 | |
| 10 | 10 | // error |
| 11 | // backend=stage2 | |
| 12 | // target=native | |
| 13 | 11 | // |
| 14 | 12 | // :2:5: error: expected 3 argument(s), found 1 |
| 15 | 13 | // :4:1: note: function declared here |
test/cases/compile_errors/wrong_number_of_arguments_for_method_fn_call.zig-2| ... | ... | @@ -12,8 +12,6 @@ export fn entry() usize { |
| 12 | 12 | } |
| 13 | 13 | |
| 14 | 14 | // error |
| 15 | // backend=stage2 | |
| 16 | // target=native | |
| 17 | 15 | // |
| 18 | 16 | // :8:8: error: member function expected 1 argument(s), found 2 |
| 19 | 17 | // :2:5: note: function declared here |
test/cases/compile_errors/wrong_pointer_coerced_to_pointer_to_opaque_{}.zig-2| ... | ... | @@ -6,8 +6,6 @@ export fn foo() void { |
| 6 | 6 | } |
| 7 | 7 | |
| 8 | 8 | // error |
| 9 | // backend=stage2 | |
| 10 | // target=native | |
| 11 | 9 | // |
| 12 | 10 | // :5:9: error: expected type '*tmp.Derp', found '*anyopaque' |
| 13 | 11 | // :5:9: note: pointer type child 'anyopaque' cannot cast into pointer type child 'tmp.Derp' |
test/cases/compile_errors/wrong_size_to_an_array_literal.zig-2| ... | ... | @@ -4,7 +4,5 @@ comptime { |
| 4 | 4 | } |
| 5 | 5 | |
| 6 | 6 | // error |
| 7 | // backend=stage2 | |
| 8 | // target=native | |
| 9 | 7 | // |
| 10 | 8 | // :2:24: error: expected 2 array elements; found 3 |
test/cases/compile_errors/wrong_type_for_reify_type.zig-2| ... | ... | @@ -3,8 +3,6 @@ export fn entry() void { |
| 3 | 3 | } |
| 4 | 4 | |
| 5 | 5 | // error |
| 6 | // backend=stage2 | |
| 7 | // target=native | |
| 8 | 6 | // |
| 9 | 7 | // :2:15: error: expected type 'builtin.Type', found 'comptime_int' |
| 10 | 8 | // :?:?: note: union declared here |
test/cases/compile_errors/wrong_type_passed_to_panic.zig-2| ... | ... | @@ -4,7 +4,5 @@ export fn entry() void { |
| 4 | 4 | } |
| 5 | 5 | |
| 6 | 6 | // error |
| 7 | // backend=stage2 | |
| 8 | // target=native | |
| 9 | 7 | // |
| 10 | 8 | // :3:12: error: expected type '[]const u8', found 'error{Foo}' |
test/cases/compile_errors/wrong_type_to_hasField.zig-2| ... | ... | @@ -3,7 +3,5 @@ export fn entry() bool { |
| 3 | 3 | } |
| 4 | 4 | |
| 5 | 5 | // error |
| 6 | // backend=stage2 | |
| 7 | // target=native | |
| 8 | 6 | // |
| 9 | 7 | // :2:22: error: type 'i32' does not support '@hasField' |
test/cases/compile_errors/wrong_types_given_to_atomic_order_args_in_cmpxchg.zig-2| ... | ... | @@ -4,8 +4,6 @@ export fn entry() void { |
| 4 | 4 | } |
| 5 | 5 | |
| 6 | 6 | // error |
| 7 | // backend=stage2 | |
| 8 | // target=native | |
| 9 | 7 | // |
| 10 | 8 | // :3:47: error: expected type 'builtin.AtomicOrder', found 'u32' |
| 11 | 9 | // :?:?: note: enum declared here |
test/cases/compile_errors/wrong_types_given_to_export.zig-2| ... | ... | @@ -4,8 +4,6 @@ comptime { |
| 4 | 4 | } |
| 5 | 5 | |
| 6 | 6 | // error |
| 7 | // backend=stage2 | |
| 8 | // target=native | |
| 9 | 7 | // |
| 10 | 8 | // :3:42: error: expected type 'builtin.GlobalLinkage', found 'u32' |
| 11 | 9 | // :?:?: note: enum declared here |
test/cases/compile_errors/zero-bit_generic_args_are_coerced_to_param_type.zig-2| ... | ... | @@ -4,8 +4,6 @@ pub export fn entry() void { |
| 4 | 4 | } |
| 5 | 5 | |
| 6 | 6 | // error |
| 7 | // backend=stage2 | |
| 8 | // target=native | |
| 9 | 7 | // |
| 10 | 8 | // :3:21: error: expected type 'u0', found '*const [4:0]u8' |
| 11 | 9 | // :1:23: note: parameter type declared here |
test/cases/error_in_nested_declaration.zig+1-2| ... | ... | @@ -23,8 +23,7 @@ pub export fn entry2() void { |
| 23 | 23 | } |
| 24 | 24 | |
| 25 | 25 | // error |
| 26 | // backend=stage2,llvm | |
| 27 | // target=native | |
| 26 | // backend=selfhosted,llvm | |
| 28 | 27 | // |
| 29 | 28 | // :6:20: error: cannot @bitCast to '[]i32' |
| 30 | 29 | // :6:20: note: use @ptrCast to cast from '[]u32' |
test/cases/f32_passed_to_variadic_fn.zig+1-1| ... | ... | @@ -7,7 +7,7 @@ pub fn main() void { |
| 7 | 7 | } |
| 8 | 8 | |
| 9 | 9 | // run |
| 10 | // backend=stage2,llvm | |
| 10 | // backend=selfhosted,llvm | |
| 11 | 11 | // target=x86_64-linux-gnu |
| 12 | 12 | // link_libc=true |
| 13 | 13 | // |
test/cases/float_mode_optimized_reduce.zig+1-1| ... | ... | @@ -8,5 +8,5 @@ pub fn main() void { |
| 8 | 8 | } |
| 9 | 9 | |
| 10 | 10 | // run |
| 11 | // backend=stage2,llvm | |
| 11 | // backend=selfhosted,llvm | |
| 12 | 12 | // target=x86_64-linux |
test/cases/fn_typeinfo_passed_to_comptime_fn.zig+1-1| ... | ... | @@ -14,5 +14,5 @@ fn foo(comptime info: std.builtin.Type) !void { |
| 14 | 14 | |
| 15 | 15 | // run |
| 16 | 16 | // is_test=true |
| 17 | // backend=stage2,llvm | |
| 17 | // backend=selfhosted,llvm | |
| 18 | 18 | // |
test/cases/large_add_function.zig+1-1| ... | ... | @@ -36,5 +36,5 @@ fn assert(ok: bool) void { |
| 36 | 36 | // TODO: enable this for native backend |
| 37 | 37 | |
| 38 | 38 | // run |
| 39 | // backend=stage2,llvm | |
| 39 | // backend=selfhosted,llvm | |
| 40 | 40 | // target=aarch64-linux,aarch64-macos |
test/cases/llvm/address_space_pointer_access_chaining_pointer_to_optional_array.zig+1-1| ... | ... | @@ -7,6 +7,6 @@ pub fn main() void { |
| 7 | 7 | |
| 8 | 8 | // compile |
| 9 | 9 | // output_mode=Exe |
| 10 | // backend=stage2,llvm | |
| 10 | // backend=selfhosted,llvm | |
| 11 | 11 | // target=x86_64-linux,x86_64-macos |
| 12 | 12 | // |
test/cases/llvm/address_spaces_pointer_access_chaining_array_pointer.zig+1-1| ... | ... | @@ -7,6 +7,6 @@ pub fn main() void { |
| 7 | 7 | |
| 8 | 8 | // compile |
| 9 | 9 | // output_mode=Exe |
| 10 | // backend=stage2,llvm | |
| 10 | // backend=selfhosted,llvm | |
| 11 | 11 | // target=x86_64-linux,x86_64-macos |
| 12 | 12 | // |
test/cases/llvm/address_spaces_pointer_access_chaining_complex.zig+1-1| ... | ... | @@ -8,6 +8,6 @@ pub fn main() void { |
| 8 | 8 | |
| 9 | 9 | // compile |
| 10 | 10 | // output_mode=Exe |
| 11 | // backend=stage2,llvm | |
| 11 | // backend=selfhosted,llvm | |
| 12 | 12 | // target=x86_64-linux,x86_64-macos |
| 13 | 13 | // |
test/cases/llvm/address_spaces_pointer_access_chaining_struct_pointer.zig+1-1| ... | ... | @@ -8,6 +8,6 @@ pub fn main() void { |
| 8 | 8 | |
| 9 | 9 | // compile |
| 10 | 10 | // output_mode=Exe |
| 11 | // backend=stage2,llvm | |
| 11 | // backend=selfhosted,llvm | |
| 12 | 12 | // target=x86_64-linux,x86_64-macos |
| 13 | 13 | // |
test/cases/llvm/blocks.zig+1-1| ... | ... | @@ -18,6 +18,6 @@ pub fn main() void { |
| 18 | 18 | } |
| 19 | 19 | |
| 20 | 20 | // run |
| 21 | // backend=stage2,llvm | |
| 21 | // backend=selfhosted,llvm | |
| 22 | 22 | // target=x86_64-linux,x86_64-macos |
| 23 | 23 | // |
test/cases/llvm/dereferencing_though_multiple_pointers_with_address_spaces.zig+1-1| ... | ... | @@ -7,6 +7,6 @@ pub fn main() void { |
| 7 | 7 | |
| 8 | 8 | // compile |
| 9 | 9 | // output_mode=Exe |
| 10 | // backend=stage2,llvm | |
| 10 | // backend=selfhosted,llvm | |
| 11 | 11 | // target=x86_64-linux,x86_64-macos |
| 12 | 12 | // |
test/cases/llvm/for_loop.zig+1-1| ... | ... | @@ -11,6 +11,6 @@ pub fn main() void { |
| 11 | 11 | } |
| 12 | 12 | |
| 13 | 13 | // run |
| 14 | // backend=stage2,llvm | |
| 14 | // backend=selfhosted,llvm | |
| 15 | 15 | // target=x86_64-linux,x86_64-macos |
| 16 | 16 | // |
test/cases/llvm/hello_world.zig+1-1| ... | ... | @@ -5,7 +5,7 @@ pub fn main() void { |
| 5 | 5 | } |
| 6 | 6 | |
| 7 | 7 | // run |
| 8 | // backend=stage2,llvm | |
| 8 | // backend=selfhosted,llvm | |
| 9 | 9 | // target=x86_64-linux,x86_64-macos |
| 10 | 10 | // link_libc=true |
| 11 | 11 | // |
test/cases/llvm/large_slices.zig+1-1| ... | ... | @@ -4,6 +4,6 @@ pub fn main() void { |
| 4 | 4 | } |
| 5 | 5 | |
| 6 | 6 | // compile |
| 7 | // backend=stage2,llvm | |
| 7 | // backend=selfhosted,llvm | |
| 8 | 8 | // target=x86_64-linux,x86_64-macos |
| 9 | 9 | // |
test/cases/llvm/nested_blocks.zig+1-1| ... | ... | @@ -19,6 +19,6 @@ pub fn main() void { |
| 19 | 19 | } |
| 20 | 20 | |
| 21 | 21 | // run |
| 22 | // backend=stage2,llvm | |
| 22 | // backend=selfhosted,llvm | |
| 23 | 23 | // target=x86_64-linux,x86_64-macos |
| 24 | 24 | // |
test/cases/llvm/optionals.zig+1-1| ... | ... | @@ -44,6 +44,6 @@ pub fn main() void { |
| 44 | 44 | } |
| 45 | 45 | |
| 46 | 46 | // run |
| 47 | // backend=stage2,llvm | |
| 47 | // backend=selfhosted,llvm | |
| 48 | 48 | // target=x86_64-linux,x86_64-macos |
| 49 | 49 | // |
test/cases/llvm/pointer_keeps_address_space.zig+1-1| ... | ... | @@ -7,6 +7,6 @@ pub fn main() void { |
| 7 | 7 | |
| 8 | 8 | // compile |
| 9 | 9 | // output_mode=Exe |
| 10 | // backend=stage2,llvm | |
| 10 | // backend=selfhosted,llvm | |
| 11 | 11 | // target=x86_64-linux,x86_64-macos |
| 12 | 12 | // |
test/cases/llvm/pointer_keeps_address_space_when_taking_address_of_dereference.zig+1-1| ... | ... | @@ -7,6 +7,6 @@ pub fn main() void { |
| 7 | 7 | |
| 8 | 8 | // compile |
| 9 | 9 | // output_mode=Exe |
| 10 | // backend=stage2,llvm | |
| 10 | // backend=selfhosted,llvm | |
| 11 | 11 | // target=x86_64-linux,x86_64-macos |
| 12 | 12 | // |
test/cases/llvm/pointer_to_explicit_generic_address_space_coerces_to_implicit_pointer.zig+1-1| ... | ... | @@ -7,6 +7,6 @@ pub fn main() void { |
| 7 | 7 | |
| 8 | 8 | // compile |
| 9 | 9 | // output_mode=Exe |
| 10 | // backend=stage2,llvm | |
| 10 | // backend=selfhosted,llvm | |
| 11 | 11 | // target=x86_64-linux,x86_64-macos |
| 12 | 12 | // |
test/cases/llvm/rem.zig+1-1| ... | ... | @@ -10,6 +10,6 @@ pub fn main() void { |
| 10 | 10 | } |
| 11 | 11 | |
| 12 | 12 | // run |
| 13 | // backend=stage2,llvm | |
| 13 | // backend=selfhosted,llvm | |
| 14 | 14 | // target=x86_64-linux,x86_64-macos |
| 15 | 15 | // |
test/cases/llvm/simple_addition_and_subtraction.zig+1-1| ... | ... | @@ -16,6 +16,6 @@ fn assert(ok: bool) void { |
| 16 | 16 | } |
| 17 | 17 | |
| 18 | 18 | // run |
| 19 | // backend=stage2,llvm | |
| 19 | // backend=selfhosted,llvm | |
| 20 | 20 | // target=x86_64-linux,x86_64-macos |
| 21 | 21 | // |
test/cases/llvm/simple_if_statement.zig+1-1| ... | ... | @@ -11,6 +11,6 @@ pub fn main() void { |
| 11 | 11 | } |
| 12 | 12 | |
| 13 | 13 | // run |
| 14 | // backend=stage2,llvm | |
| 14 | // backend=selfhosted,llvm | |
| 15 | 15 | // target=x86_64-linux,x86_64-macos |
| 16 | 16 | // |
test/cases/llvm/while_loops.zig+1-1| ... | ... | @@ -13,6 +13,6 @@ pub fn main() void { |
| 13 | 13 | } |
| 14 | 14 | |
| 15 | 15 | // run |
| 16 | // backend=stage2,llvm | |
| 16 | // backend=selfhosted,llvm | |
| 17 | 17 | // target=x86_64-linux,x86_64-macos |
| 18 | 18 | // |
test/cases/maximum_sized_integer_literal.zig+1-2| ... | ... | @@ -18,5 +18,4 @@ pub fn main() !void { |
| 18 | 18 | } |
| 19 | 19 | |
| 20 | 20 | // run |
| 21 | // backend=stage2,llvm | |
| 22 | // target=native | |
| 21 | // backend=selfhosted,llvm |
test/cases/pic_freestanding.zig+1-1| ... | ... | @@ -8,7 +8,7 @@ comptime { |
| 8 | 8 | } |
| 9 | 9 | |
| 10 | 10 | // compile |
| 11 | // backend=stage2,llvm | |
| 11 | // backend=selfhosted,llvm | |
| 12 | 12 | // target=arm-freestanding,armeb-freestanding,thumb-freestanding,thumbeb-freestanding,aarch64-freestanding,aarch64_be-freestanding,loongarch64-freestanding,mips-freestanding,mipsel-freestanding,mips64-freestanding,mips64el-freestanding,powerpc-freestanding,powerpcle-freestanding,powerpc64-freestanding,powerpc64le-freestanding,riscv32-freestanding,riscv64-freestanding,s390x-freestanding,x86-freestanding,x86_64-freestanding |
| 13 | 13 | // pic=true |
| 14 | 14 | // output_mode=Exe |
test/cases/pic_linux.zig+1-1| ... | ... | @@ -8,7 +8,7 @@ const std = @import("std"); |
| 8 | 8 | pub fn main() void {} |
| 9 | 9 | |
| 10 | 10 | // run |
| 11 | // backend=stage2,llvm | |
| 11 | // backend=selfhosted,llvm | |
| 12 | 12 | // target=arm-linux,armeb-linux,thumb-linux,thumbeb-linux,aarch64-linux,aarch64_be-linux,loongarch64-linux,mips-linux,mipsel-linux,mips64-linux,mips64el-linux,powerpc-linux,powerpc64-linux,powerpc64le-linux,riscv32-linux,riscv64-linux,s390x-linux,x86-linux,x86_64-linux |
| 13 | 13 | // pic=true |
| 14 | 14 | // link_libc=true |
test/cases/returning_undefined_sentinel_terminated_const_u8_slice.zig+1-2| ... | ... | @@ -7,5 +7,4 @@ pub fn main() void { |
| 7 | 7 | } |
| 8 | 8 | |
| 9 | 9 | // run |
| 10 | // backend=stage2,llvm | |
| 11 | // target=native | |
| 10 | // backend=selfhosted,llvm |
test/cases/safety/@alignCast misaligned.zig	+1-1| ... | ... | @@ -21,5 +21,5 @@ fn foo(bytes: []u8) u32 { |
| 21 | 21 | return int_slice[0]; |
| 22 | 22 | } |
| 23 | 23 | // run |
| 24 | // backend=stage2,llvm | |
| 24 | // backend=selfhosted,llvm | |
| 25 | 25 | // target=x86_64-linux,aarch64-linux |
test/cases/safety/@enumFromInt - no matching tag value.zig	+1-1| ... | ... | @@ -22,5 +22,5 @@ fn bar(a: u2) Foo { |
| 22 | 22 | fn baz(_: Foo) void {} |
| 23 | 23 | |
| 24 | 24 | // run |
| 25 | // backend=stage2,llvm | |
| 25 | // backend=selfhosted,llvm | |
| 26 | 26 | // target=x86_64-linux |
test/cases/safety/@enumFromInt truncated bits - exhaustive.zig	+1-1| ... | ... | @@ -19,5 +19,5 @@ pub fn main() u8 { |
| 19 | 19 | } |
| 20 | 20 | |
| 21 | 21 | // run |
| 22 | // backend=stage2,llvm | |
| 22 | // backend=selfhosted,llvm | |
| 23 | 23 | // target=x86_64-linux |
test/cases/safety/@enumFromInt truncated bits - nonexhaustive.zig	+1-1| ... | ... | @@ -19,5 +19,5 @@ pub fn main() u8 { |
| 19 | 19 | } |
| 20 | 20 | |
| 21 | 21 | // run |
| 22 | // backend=stage2,llvm | |
| 22 | // backend=selfhosted,llvm | |
| 23 | 23 | // target=x86_64-linux |
test/cases/safety/@errorCast error not present in destination.zig	+1-1| ... | ... | @@ -17,5 +17,5 @@ fn foo(set1: Set1) Set2 { |
| 17 | 17 | return @errorCast(set1); |
| 18 | 18 | } |
| 19 | 19 | // run |
| 20 | // backend=stage2,llvm | |
| 20 | // backend=selfhosted,llvm | |
| 21 | 21 | // target=x86_64-linux |
test/cases/safety/@errorCast error union casted to disjoint set.zig	+1-1| ... | ... | @@ -16,5 +16,5 @@ fn foo() anyerror!i32 { |
| 16 | 16 | return error.Bar; |
| 17 | 17 | } |
| 18 | 18 | // run |
| 19 | // backend=stage2,llvm | |
| 19 | // backend=selfhosted,llvm | |
| 20 | 20 | // target=x86_64-linux |
test/cases/safety/@intCast to u0.zig	+1-1| ... | ... | @@ -18,5 +18,5 @@ fn bar(one: u1, not_zero: i32) void { |
| 18 | 18 | _ = x; |
| 19 | 19 | } |
| 20 | 20 | // run |
| 21 | // backend=stage2,llvm | |
| 21 | // backend=selfhosted,llvm | |
| 22 | 22 | // target=x86_64-linux,aarch64-linux |
test/cases/safety/@intFromFloat cannot fit - boundary case - i0 max.zig	+1-1| ... | ... | @@ -12,5 +12,5 @@ pub fn main() !void { |
| 12 | 12 | return error.TestFailed; |
| 13 | 13 | } |
| 14 | 14 | // run |
| 15 | // backend=stage2,llvm | |
| 15 | // backend=selfhosted,llvm | |
| 16 | 16 | // target=x86_64-linux,aarch64-linux |
test/cases/safety/@intFromFloat cannot fit - boundary case - i0 min.zig	+1-1| ... | ... | @@ -12,5 +12,5 @@ pub fn main() !void { |
| 12 | 12 | return error.TestFailed; |
| 13 | 13 | } |
| 14 | 14 | // run |
| 15 | // backend=stage2,llvm | |
| 15 | // backend=selfhosted,llvm | |
| 16 | 16 | // target=x86_64-linux,aarch64-linux |
test/cases/safety/@intFromFloat cannot fit - boundary case - signed max.zig	+1-1| ... | ... | @@ -12,5 +12,5 @@ pub fn main() !void { |
| 12 | 12 | return error.TestFailed; |
| 13 | 13 | } |
| 14 | 14 | // run |
| 15 | // backend=stage2,llvm | |
| 15 | // backend=selfhosted,llvm | |
| 16 | 16 | // target=x86_64-linux |
test/cases/safety/@intFromFloat cannot fit - boundary case - signed min.zig	+1-1| ... | ... | @@ -12,5 +12,5 @@ pub fn main() !void { |
| 12 | 12 | return error.TestFailed; |
| 13 | 13 | } |
| 14 | 14 | // run |
| 15 | // backend=stage2,llvm | |
| 15 | // backend=selfhosted,llvm | |
| 16 | 16 | // target=x86_64-linux |
test/cases/safety/@intFromFloat cannot fit - boundary case - u0 max.zig	+1-1| ... | ... | @@ -12,5 +12,5 @@ pub fn main() !void { |
| 12 | 12 | return error.TestFailed; |
| 13 | 13 | } |
| 14 | 14 | // run |
| 15 | // backend=stage2,llvm | |
| 15 | // backend=selfhosted,llvm | |
| 16 | 16 | // target=x86_64-linux,aarch64-linux |
test/cases/safety/@intFromFloat cannot fit - boundary case - u0 min.zig	+1-1| ... | ... | @@ -12,5 +12,5 @@ pub fn main() !void { |
| 12 | 12 | return error.TestFailed; |
| 13 | 13 | } |
| 14 | 14 | // run |
| 15 | // backend=stage2,llvm | |
| 15 | // backend=selfhosted,llvm | |
| 16 | 16 | // target=x86_64-linux,aarch64-linux |
test/cases/safety/@intFromFloat cannot fit - boundary case - unsigned max.zig	+1-1| ... | ... | @@ -12,5 +12,5 @@ pub fn main() !void { |
| 12 | 12 | return error.TestFailed; |
| 13 | 13 | } |
| 14 | 14 | // run |
| 15 | // backend=stage2,llvm | |
| 15 | // backend=selfhosted,llvm | |
| 16 | 16 | // target=x86_64-linux |
test/cases/safety/@intFromFloat cannot fit - boundary case - unsigned min.zig	+1-1| ... | ... | @@ -12,5 +12,5 @@ pub fn main() !void { |
| 12 | 12 | return error.TestFailed; |
| 13 | 13 | } |
| 14 | 14 | // run |
| 15 | // backend=stage2,llvm | |
| 15 | // backend=selfhosted,llvm | |
| 16 | 16 | // target=x86_64-linux |
test/cases/safety/@intFromFloat cannot fit - boundary case - vector max.zig	+1-1| ... | ... | @@ -12,5 +12,5 @@ pub fn main() !void { |
| 12 | 12 | return error.TestFailed; |
| 13 | 13 | } |
| 14 | 14 | // run |
| 15 | // backend=stage2,llvm | |
| 15 | // backend=selfhosted,llvm | |
| 16 | 16 | // target=x86_64-linux |
test/cases/safety/@intFromFloat cannot fit - boundary case - vector min.zig	+1-1| ... | ... | @@ -12,5 +12,5 @@ pub fn main() !void { |
| 12 | 12 | return error.TestFailed; |
| 13 | 13 | } |
| 14 | 14 | // run |
| 15 | // backend=stage2,llvm | |
| 15 | // backend=selfhosted,llvm | |
| 16 | 16 | // target=x86_64-linux |
test/cases/safety/@intFromFloat cannot fit - negative out of range.zig	+1-1| ... | ... | @@ -16,5 +16,5 @@ fn bar(a: f32) i8 { |
| 16 | 16 | } |
| 17 | 17 | fn baz(_: i8) void {} |
| 18 | 18 | // run |
| 19 | // backend=stage2,llvm | |
| 19 | // backend=selfhosted,llvm | |
| 20 | 20 | // target=x86_64-linux |
test/cases/safety/@intFromFloat cannot fit - negative to unsigned.zig	+1-1| ... | ... | @@ -16,5 +16,5 @@ fn bar(a: f32) u8 { |
| 16 | 16 | } |
| 17 | 17 | fn baz(_: u8) void {} |
| 18 | 18 | // run |
| 19 | // backend=stage2,llvm | |
| 19 | // backend=selfhosted,llvm | |
| 20 | 20 | // target=x86_64-linux |
test/cases/safety/@intFromFloat cannot fit - positive out of range.zig	+1-1| ... | ... | @@ -16,5 +16,5 @@ fn bar(a: f32) u8 { |
| 16 | 16 | } |
| 17 | 17 | fn baz(_: u8) void {} |
| 18 | 18 | // run |
| 19 | // backend=stage2,llvm | |
| 19 | // backend=selfhosted,llvm | |
| 20 | 20 | // target=x86_64-linux |
test/cases/safety/@ptrFromInt address zero to non-optional byte-aligned pointer.zig	+1-1| ... | ... | @@ -15,5 +15,5 @@ pub fn main() !void { |
| 15 | 15 | return error.TestFailed; |
| 16 | 16 | } |
| 17 | 17 | // run |
| 18 | // backend=stage2,llvm | |
| 18 | // backend=selfhosted,llvm | |
| 19 | 19 | // target=x86_64-linux,aarch64-linux |
test/cases/safety/@ptrFromInt address zero to non-optional pointer.zig	+1-1| ... | ... | @@ -15,5 +15,5 @@ pub fn main() !void { |
| 15 | 15 | return error.TestFailed; |
| 16 | 16 | } |
| 17 | 17 | // run |
| 18 | // backend=stage2,llvm | |
| 18 | // backend=selfhosted,llvm | |
| 19 | 19 | // target=x86_64-linux,aarch64-linux |
test/cases/safety/@ptrFromInt with misaligned address.zig	+1-1| ... | ... | @@ -15,5 +15,5 @@ pub fn main() !void { |
| 15 | 15 | return error.TestFailed; |
| 16 | 16 | } |
| 17 | 17 | // run |
| 18 | // backend=stage2,llvm | |
| 18 | // backend=selfhosted,llvm | |
| 19 | 19 | // target=x86_64-linux,aarch64-linux |
test/cases/safety/@tagName on corrupted enum value.zig	+1-1| ... | ... | @@ -22,5 +22,5 @@ pub fn main() !void { |
| 22 | 22 | } |
| 23 | 23 | |
| 24 | 24 | // run |
| 25 | // backend=stage2,llvm | |
| 25 | // backend=selfhosted,llvm | |
| 26 | 26 | // target=x86_64-linux |
test/cases/safety/@tagName on corrupted union value.zig	+1-1| ... | ... | @@ -23,5 +23,5 @@ pub fn main() !void { |
| 23 | 23 | } |
| 24 | 24 | |
| 25 | 25 | // run |
| 26 | // backend=stage2,llvm | |
| 26 | // backend=selfhosted,llvm | |
| 27 | 27 | // target=x86_64-linux |
test/cases/safety/array slice sentinel mismatch vector.zig	+1-1| ... | ... | @@ -15,5 +15,5 @@ pub fn main() !void { |
| 15 | 15 | return error.TestFailed; |
| 16 | 16 | } |
| 17 | 17 | // run |
| 18 | // backend=stage2,llvm | |
| 18 | // backend=selfhosted,llvm | |
| 19 | 19 | // target=x86_64-linux |
test/cases/safety/array slice sentinel mismatch.zig	+1-1| ... | ... | @@ -15,5 +15,5 @@ pub fn main() !void { |
| 15 | 15 | return error.TestFailed; |
| 16 | 16 | } |
| 17 | 17 | // run |
| 18 | // backend=stage2,llvm | |
| 18 | // backend=selfhosted,llvm | |
| 19 | 19 | // target=x86_64-linux,aarch64-linux |
test/cases/safety/bad union field access.zig	+1-1| ... | ... | @@ -23,5 +23,5 @@ fn bar(f: *Foo) void { |
| 23 | 23 | f.float = 12.34; |
| 24 | 24 | } |
| 25 | 25 | // run |
| 26 | // backend=stage2,llvm | |
| 26 | // backend=selfhosted,llvm | |
| 27 | 27 | // target=x86_64-linux |
test/cases/safety/calling panic.zig	+1-1| ... | ... | @@ -12,5 +12,5 @@ pub fn main() !void { |
| 12 | 12 | return error.TestFailed; |
| 13 | 13 | } |
| 14 | 14 | // run |
| 15 | // backend=stage2,llvm | |
| 15 | // backend=selfhosted,llvm | |
| 16 | 16 | // target=x86_64-linux,aarch64-linux |
test/cases/safety/cast []u8 to bigger slice of wrong size.zig	+1-1| ... | ... | @@ -17,5 +17,5 @@ fn widenSlice(slice: []align(1) const u8) []align(1) const i32 { |
| 17 | 17 | return std.mem.bytesAsSlice(i32, slice); |
| 18 | 18 | } |
| 19 | 19 | // run |
| 20 | // backend=stage2,llvm | |
| 20 | // backend=selfhosted,llvm | |
| 21 | 21 | // target=x86_64-linux,aarch64-linux |
test/cases/safety/cast integer to global error and no code matches.zig	+1-1| ... | ... | @@ -15,5 +15,5 @@ fn bar(x: u16) anyerror { |
| 15 | 15 | return @errorFromInt(x); |
| 16 | 16 | } |
| 17 | 17 | // run |
| 18 | // backend=stage2,llvm | |
| 18 | // backend=selfhosted,llvm | |
| 19 | 19 | // target=x86_64-linux,aarch64-linux |
test/cases/safety/empty slice with sentinel out of bounds.zig	+1-1| ... | ... | @@ -17,5 +17,5 @@ pub fn main() !void { |
| 17 | 17 | } |
| 18 | 18 | |
| 19 | 19 | // run |
| 20 | // backend=stage2,llvm | |
| 20 | // backend=selfhosted,llvm | |
| 21 | 21 | // target=x86_64-linux,aarch64-linux |
test/cases/safety/exact division failure - vectors.zig	+1-1| ... | ... | @@ -19,5 +19,5 @@ fn divExact(a: @Vector(4, i32), b: @Vector(4, i32)) @Vector(4, i32) { |
| 19 | 19 | return @divExact(a, b); |
| 20 | 20 | } |
| 21 | 21 | // run |
| 22 | // backend=stage2,llvm | |
| 22 | // backend=selfhosted,llvm | |
| 23 | 23 | // target=x86_64-linux |
test/cases/safety/exact division failure.zig	+1-1| ... | ... | @@ -17,5 +17,5 @@ fn divExact(a: i32, b: i32) i32 { |
| 17 | 17 | return @divExact(a, b); |
| 18 | 18 | } |
| 19 | 19 | // run |
| 20 | // backend=stage2,llvm | |
| 20 | // backend=selfhosted,llvm | |
| 21 | 21 | // target=x86_64-linux,aarch64-linux |
test/cases/safety/for_len_mismatch.zig+1-1| ... | ... | @@ -21,5 +21,5 @@ pub fn main() !void { |
| 21 | 21 | return error.TestFailed; |
| 22 | 22 | } |
| 23 | 23 | // run |
| 24 | // backend=stage2,llvm | |
| 24 | // backend=selfhosted,llvm | |
| 25 | 25 | // target=x86_64-linux,aarch64-linux |
test/cases/safety/for_len_mismatch_three.zig+1-1| ... | ... | @@ -20,5 +20,5 @@ pub fn main() !void { |
| 20 | 20 | return error.TestFailed; |
| 21 | 21 | } |
| 22 | 22 | // run |
| 23 | // backend=stage2,llvm | |
| 23 | // backend=selfhosted,llvm | |
| 24 | 24 | // target=x86_64-linux,aarch64-linux |
test/cases/safety/ignored expression integer overflow.zig	+1-1| ... | ... | @@ -17,5 +17,5 @@ pub fn main() !void { |
| 17 | 17 | } |
| 18 | 18 | |
| 19 | 19 | // run |
| 20 | // backend=stage2,llvm | |
| 20 | // backend=selfhosted,llvm | |
| 21 | 21 | // target=x86_64-linux |
test/cases/safety/integer addition overflow.zig	+1-1| ... | ... | @@ -19,5 +19,5 @@ fn add(a: u16, b: u16) u16 { |
| 19 | 19 | } |
| 20 | 20 | |
| 21 | 21 | // run |
| 22 | // backend=stage2,llvm | |
| 22 | // backend=selfhosted,llvm | |
| 23 | 23 | // target=x86_64-linux,aarch64-linux |
test/cases/safety/integer division by zero - vectors.zig	+1-1| ... | ... | @@ -18,5 +18,5 @@ fn div0(a: @Vector(4, i32), b: @Vector(4, i32)) @Vector(4, i32) { |
| 18 | 18 | return @divTrunc(a, b); |
| 19 | 19 | } |
| 20 | 20 | // run |
| 21 | // backend=stage2,llvm | |
| 21 | // backend=selfhosted,llvm | |
| 22 | 22 | // target=x86_64-linux |
test/cases/safety/integer division by zero.zig	+1-1| ... | ... | @@ -16,5 +16,5 @@ fn div0(a: i32, b: i32) i32 { |
| 16 | 16 | return @divTrunc(a, b); |
| 17 | 17 | } |
| 18 | 18 | // run |
| 19 | // backend=stage2,llvm | |
| 19 | // backend=selfhosted,llvm | |
| 20 | 20 | // target=x86_64-linux,aarch64-linux |
test/cases/safety/integer multiplication overflow.zig	+1-1| ... | ... | @@ -17,5 +17,5 @@ fn mul(a: u16, b: u16) u16 { |
| 17 | 17 | return a * b; |
| 18 | 18 | } |
| 19 | 19 | // run |
| 20 | // backend=stage2,llvm | |
| 20 | // backend=selfhosted,llvm | |
| 21 | 21 | // target=x86_64-linux,aarch64-linux |
test/cases/safety/integer negation overflow.zig	+1-1| ... | ... | @@ -17,5 +17,5 @@ fn neg(a: i16) i16 { |
| 17 | 17 | return -a; |
| 18 | 18 | } |
| 19 | 19 | // run |
| 20 | // backend=stage2,llvm | |
| 20 | // backend=selfhosted,llvm | |
| 21 | 21 | // target=x86_64-linux,aarch64-linux |
test/cases/safety/integer subtraction overflow.zig	+1-1| ... | ... | @@ -17,5 +17,5 @@ fn sub(a: u16, b: u16) u16 { |
| 17 | 17 | return a - b; |
| 18 | 18 | } |
| 19 | 19 | // run |
| 20 | // backend=stage2,llvm | |
| 20 | // backend=selfhosted,llvm | |
| 21 | 21 | // target=x86_64-linux,aarch64-linux |
test/cases/safety/memcpy_alias.zig+1-1| ... | ... | @@ -15,5 +15,5 @@ pub fn main() !void { |
| 15 | 15 | return error.TestFailed; |
| 16 | 16 | } |
| 17 | 17 | // run |
| 18 | // backend=stage2,llvm | |
| 18 | // backend=selfhosted,llvm | |
| 19 | 19 | // target=x86_64-linux,aarch64-linux |
test/cases/safety/memcpy_len_mismatch.zig+1-1| ... | ... | @@ -15,5 +15,5 @@ pub fn main() !void { |
| 15 | 15 | return error.TestFailed; |
| 16 | 16 | } |
| 17 | 17 | // run |
| 18 | // backend=stage2,llvm | |
| 18 | // backend=selfhosted,llvm | |
| 19 | 19 | // target=x86_64-linux,aarch64-linux |
test/cases/safety/memmove_len_mismatch.zig+1-1| ... | ... | @@ -15,5 +15,5 @@ pub fn main() !void { |
| 15 | 15 | return error.TestFailed; |
| 16 | 16 | } |
| 17 | 17 | // run |
| 18 | // backend=stage2,llvm | |
| 18 | // backend=selfhosted,llvm | |
| 19 | 19 | // target=x86_64-linux,aarch64-linux |
test/cases/safety/memset_array_undefined_bytes.zig+1-1| ... | ... | @@ -14,5 +14,5 @@ pub fn main() !void { |
| 14 | 14 | x += buffer[2]; |
| 15 | 15 | } |
| 16 | 16 | // run |
| 17 | // backend=stage2,llvm | |
| 17 | // backend=selfhosted,llvm | |
| 18 | 18 | // target=x86_64-linux,aarch64-linux |
test/cases/safety/memset_array_undefined_large.zig+1-1| ... | ... | @@ -14,5 +14,5 @@ pub fn main() !void { |
| 14 | 14 | x += buffer[2]; |
| 15 | 15 | } |
| 16 | 16 | // run |
| 17 | // backend=stage2,llvm | |
| 17 | // backend=selfhosted,llvm | |
| 18 | 18 | // target=x86_64-linux,aarch64-linux |
test/cases/safety/memset_slice_undefined_bytes.zig+1-1| ... | ... | @@ -16,5 +16,5 @@ pub fn main() !void { |
| 16 | 16 | x += buffer[2]; |
| 17 | 17 | } |
| 18 | 18 | // run |
| 19 | // backend=stage2,llvm | |
| 19 | // backend=selfhosted,llvm | |
| 20 | 20 | // target=x86_64-linux,aarch64-linux |
test/cases/safety/memset_slice_undefined_large.zig+1-1| ... | ... | @@ -16,5 +16,5 @@ pub fn main() !void { |
| 16 | 16 | x += buffer[2]; |
| 17 | 17 | } |
| 18 | 18 | // run |
| 19 | // backend=stage2,llvm | |
| 19 | // backend=selfhosted,llvm | |
| 20 | 20 | // target=x86_64-linux,aarch64-linux |
test/cases/safety/modrem by zero.zig	+1-1| ... | ... | @@ -16,5 +16,5 @@ fn div0(a: u32, b: u32) u32 { |
| 16 | 16 | return a / b; |
| 17 | 17 | } |
| 18 | 18 | // run |
| 19 | // backend=stage2,llvm | |
| 19 | // backend=selfhosted,llvm | |
| 20 | 20 | // target=x86_64-linux,aarch64-linux |
test/cases/safety/modulus by zero.zig	+1-1| ... | ... | @@ -16,5 +16,5 @@ fn mod0(a: i32, b: i32) i32 { |
| 16 | 16 | return @mod(a, b); |
| 17 | 17 | } |
| 18 | 18 | // run |
| 19 | // backend=stage2,llvm | |
| 19 | // backend=selfhosted,llvm | |
| 20 | 20 | // target=x86_64-linux |
test/cases/safety/noreturn returned.zig	+1-1| ... | ... | @@ -19,5 +19,5 @@ pub fn main() void { |
| 19 | 19 | bar(); |
| 20 | 20 | } |
| 21 | 21 | // run |
| 22 | // backend=stage2,llvm | |
| 22 | // backend=selfhosted,llvm | |
| 23 | 23 | // target=x86_64-linux,aarch64-linux |
test/cases/safety/optional unwrap operator on C pointer.zig	+1-1| ... | ... | @@ -15,5 +15,5 @@ pub fn main() !void { |
| 15 | 15 | return error.TestFailed; |
| 16 | 16 | } |
| 17 | 17 | // run |
| 18 | // backend=stage2,llvm | |
| 18 | // backend=selfhosted,llvm | |
| 19 | 19 | // target=x86_64-linux,aarch64-linux |
test/cases/safety/optional unwrap operator on null pointer.zig	+1-1| ... | ... | @@ -15,5 +15,5 @@ pub fn main() !void { |
| 15 | 15 | return error.TestFailed; |
| 16 | 16 | } |
| 17 | 17 | // run |
| 18 | // backend=stage2,llvm | |
| 18 | // backend=selfhosted,llvm | |
| 19 | 19 | // target=x86_64-linux,aarch64-linux |
test/cases/safety/optional_empty_error_set.zig+1-1| ... | ... | @@ -18,5 +18,5 @@ fn foo() !void { |
| 18 | 18 | return x.?; |
| 19 | 19 | } |
| 20 | 20 | // run |
| 21 | // backend=stage2,llvm | |
| 21 | // backend=selfhosted,llvm | |
| 22 | 22 | // target=x86_64-linux,aarch64-linux |
test/cases/safety/out of bounds array slice by length.zig	+1-1| ... | ... | @@ -16,5 +16,5 @@ fn foo(a: u32) u32 { |
| 16 | 16 | return a; |
| 17 | 17 | } |
| 18 | 18 | // run |
| 19 | // backend=stage2,llvm | |
| 19 | // backend=selfhosted,llvm | |
| 20 | 20 | // target=x86_64-linux,aarch64-linux |
test/cases/safety/out of bounds slice access.zig	+1-1| ... | ... | @@ -17,5 +17,5 @@ fn bar(a: []const i32) i32 { |
| 17 | 17 | } |
| 18 | 18 | fn baz(_: i32) void {} |
| 19 | 19 | // run |
| 20 | // backend=stage2,llvm | |
| 20 | // backend=selfhosted,llvm | |
| 21 | 21 | // target=x86_64-linux,aarch64-linux |
test/cases/safety/pointer casting null to non-optional pointer.zig	+1-1| ... | ... | @@ -17,5 +17,5 @@ pub fn main() !void { |
| 17 | 17 | } |
| 18 | 18 | |
| 19 | 19 | // run |
| 20 | // backend=stage2,llvm | |
| 20 | // backend=selfhosted,llvm | |
| 21 | 21 | // target=x86_64-linux,aarch64-linux |
test/cases/safety/pointer casting to null function pointer.zig	+1-1| ... | ... | @@ -19,5 +19,5 @@ pub fn main() !void { |
| 19 | 19 | } |
| 20 | 20 | |
| 21 | 21 | // run |
| 22 | // backend=stage2,llvm | |
| 22 | // backend=selfhosted,llvm | |
| 23 | 23 | // target=x86_64-linux,aarch64-linux |
test/cases/safety/pointer slice sentinel mismatch.zig	+1-1| ... | ... | @@ -17,5 +17,5 @@ pub fn main() !void { |
| 17 | 17 | } |
| 18 | 18 | |
| 19 | 19 | // run |
| 20 | // backend=stage2,llvm | |
| 20 | // backend=selfhosted,llvm | |
| 21 | 21 | // target=x86_64-linux,aarch64-linux |
test/cases/safety/remainder division by zero.zig	+1-1| ... | ... | @@ -16,5 +16,5 @@ fn rem0(a: i32, b: i32) i32 { |
| 16 | 16 | return @rem(a, b); |
| 17 | 17 | } |
| 18 | 18 | // run |
| 19 | // backend=stage2,llvm | |
| 19 | // backend=selfhosted,llvm | |
| 20 | 20 | // target=x86_64-linux,aarch64-linux |
test/cases/safety/shift left by huge amount.zig	+1-1| ... | ... | @@ -18,5 +18,5 @@ pub fn main() !void { |
| 18 | 18 | } |
| 19 | 19 | |
| 20 | 20 | // run |
| 21 | // backend=stage2,llvm | |
| 21 | // backend=selfhosted,llvm | |
| 22 | 22 | // target=x86_64-linux,aarch64-linux |
test/cases/safety/shift right by huge amount.zig	+1-1| ... | ... | @@ -18,5 +18,5 @@ pub fn main() !void { |
| 18 | 18 | } |
| 19 | 19 | |
| 20 | 20 | // run |
| 21 | // backend=stage2,llvm | |
| 21 | // backend=selfhosted,llvm | |
| 22 | 22 | // target=x86_64-linux,aarch64-linux |
test/cases/safety/signed integer division overflow - vectors.zig	+1-1| ... | ... | @@ -19,5 +19,5 @@ fn div(a: @Vector(4, i16), b: @Vector(4, i16)) @Vector(4, i16) { |
| 19 | 19 | return @divTrunc(a, b); |
| 20 | 20 | } |
| 21 | 21 | // run |
| 22 | // backend=stage2,llvm | |
| 22 | // backend=selfhosted,llvm | |
| 23 | 23 | // target=x86_64-linux |
test/cases/safety/signed integer division overflow.zig	+1-1| ... | ... | @@ -17,5 +17,5 @@ fn div(a: i16, b: i16) i16 { |
| 17 | 17 | return @divTrunc(a, b); |
| 18 | 18 | } |
| 19 | 19 | // run |
| 20 | // backend=stage2,llvm | |
| 20 | // backend=selfhosted,llvm | |
| 21 | 21 | // target=x86_64-linux,aarch64-linux |
test/cases/safety/signed integer not fitting in cast to unsigned integer - widening.zig	+1-1| ... | ... | @@ -15,5 +15,5 @@ pub fn main() !void { |
| 15 | 15 | return error.TestFailed; |
| 16 | 16 | } |
| 17 | 17 | // run |
| 18 | // backend=stage2,llvm | |
| 18 | // backend=selfhosted,llvm | |
| 19 | 19 | // target=x86_64-linux |
test/cases/safety/signed integer not fitting in cast to unsigned integer.zig	+1-1| ... | ... | @@ -16,5 +16,5 @@ fn unsigned_cast(x: i32) u32 { |
| 16 | 16 | return @intCast(x); |
| 17 | 17 | } |
| 18 | 18 | // run |
| 19 | // backend=stage2,llvm | |
| 19 | // backend=selfhosted,llvm | |
| 20 | 20 | // target=x86_64-linux,aarch64-linux |
test/cases/safety/signed shift left overflow.zig	+1-1| ... | ... | @@ -17,5 +17,5 @@ fn shl(a: i16, b: u4) i16 { |
| 17 | 17 | return @shlExact(a, b); |
| 18 | 18 | } |
| 19 | 19 | // run |
| 20 | // backend=stage2,llvm | |
| 20 | // backend=selfhosted,llvm | |
| 21 | 21 | // target=x86_64-linux |
test/cases/safety/signed shift right overflow.zig	+1-1| ... | ... | @@ -17,5 +17,5 @@ fn shr(a: i16, b: u4) i16 { |
| 17 | 17 | return @shrExact(a, b); |
| 18 | 18 | } |
| 19 | 19 | // run |
| 20 | // backend=stage2,llvm | |
| 20 | // backend=selfhosted,llvm | |
| 21 | 21 | // target=x86_64-linux,aarch64-linux |
test/cases/safety/signed-unsigned vector cast.zig	+1-1| ... | ... | @@ -17,5 +17,5 @@ pub fn main() !void { |
| 17 | 17 | } |
| 18 | 18 | |
| 19 | 19 | // run |
| 20 | // backend=stage2,llvm | |
| 20 | // backend=selfhosted,llvm | |
| 21 | 21 | // target=x86_64-linux |
test/cases/safety/slice by length sentinel mismatch on lhs.zig	+1-1| ... | ... | @@ -14,5 +14,5 @@ pub fn main() !void { |
| 14 | 14 | return error.TestFailed; |
| 15 | 15 | } |
| 16 | 16 | // run |
| 17 | // backend=stage2,llvm | |
| 17 | // backend=selfhosted,llvm | |
| 18 | 18 | // target=x86_64-linux,aarch64-linux |
test/cases/safety/slice by length sentinel mismatch on rhs.zig	+1-1| ... | ... | @@ -14,5 +14,5 @@ pub fn main() !void { |
| 14 | 14 | return error.TestFailed; |
| 15 | 15 | } |
| 16 | 16 | // run |
| 17 | // backend=stage2,llvm | |
| 17 | // backend=selfhosted,llvm | |
| 18 | 18 | // target=x86_64-linux,aarch64-linux |
test/cases/safety/slice sentinel mismatch - floats.zig	+1-1| ... | ... | @@ -16,5 +16,5 @@ pub fn main() !void { |
| 16 | 16 | } |
| 17 | 17 | |
| 18 | 18 | // run |
| 19 | // backend=stage2,llvm | |
| 19 | // backend=selfhosted,llvm | |
| 20 | 20 | // target=x86_64-linux |
test/cases/safety/slice sentinel mismatch - optional pointers.zig	+1-1| ... | ... | @@ -16,5 +16,5 @@ pub fn main() !void { |
| 16 | 16 | } |
| 17 | 17 | |
| 18 | 18 | // run |
| 19 | // backend=stage2,llvm | |
| 19 | // backend=selfhosted,llvm | |
| 20 | 20 | // target=x86_64-linux,aarch64-linux |
test/cases/safety/slice slice sentinel mismatch.zig	+1-1| ... | ... | @@ -15,5 +15,5 @@ pub fn main() !void { |
| 15 | 15 | return error.TestFailed; |
| 16 | 16 | } |
| 17 | 17 | // run |
| 18 | // backend=stage2,llvm | |
| 18 | // backend=selfhosted,llvm | |
| 19 | 19 | // target=x86_64-linux,aarch64-linux |
test/cases/safety/slice start index greater than end index.zig	+1-1| ... | ... | @@ -20,5 +20,5 @@ pub fn main() !void { |
| 20 | 20 | } |
| 21 | 21 | |
| 22 | 22 | // run |
| 23 | // backend=stage2,llvm | |
| 23 | // backend=selfhosted,llvm | |
| 24 | 24 | // target=x86_64-linux,aarch64-linux |
test/cases/safety/slice with sentinel out of bounds - runtime len.zig	+1-1| ... | ... | @@ -19,5 +19,5 @@ pub fn main() !void { |
| 19 | 19 | } |
| 20 | 20 | |
| 21 | 21 | // run |
| 22 | // backend=stage2,llvm | |
| 22 | // backend=selfhosted,llvm | |
| 23 | 23 | // target=x86_64-linux,aarch64-linux |
test/cases/safety/slice with sentinel out of bounds.zig	+1-1| ... | ... | @@ -17,5 +17,5 @@ pub fn main() !void { |
| 17 | 17 | } |
| 18 | 18 | |
| 19 | 19 | // run |
| 20 | // backend=stage2,llvm | |
| 20 | // backend=selfhosted,llvm | |
| 21 | 21 | // target=x86_64-linux,aarch64-linux |
test/cases/safety/slice_cast_change_len_0.zig+1-1| ... | ... | @@ -23,5 +23,5 @@ pub fn panic(message: []const u8, _: ?*std.builtin.StackTrace, _: ?usize) noretu |
| 23 | 23 | const std = @import("std"); |
| 24 | 24 | |
| 25 | 25 | // run |
| 26 | // backend=stage2,llvm | |
| 26 | // backend=selfhosted,llvm | |
| 27 | 27 | // target=x86_64-linux,aarch64-linux |
test/cases/safety/slice_cast_change_len_1.zig+1-1| ... | ... | @@ -23,5 +23,5 @@ pub fn panic(message: []const u8, _: ?*std.builtin.StackTrace, _: ?usize) noretu |
| 23 | 23 | const std = @import("std"); |
| 24 | 24 | |
| 25 | 25 | // run |
| 26 | // backend=stage2,llvm | |
| 26 | // backend=selfhosted,llvm | |
| 27 | 27 | // target=x86_64-linux,aarch64-linux |
test/cases/safety/slice_cast_change_len_2.zig+1-1| ... | ... | @@ -23,5 +23,5 @@ pub fn panic(message: []const u8, _: ?*std.builtin.StackTrace, _: ?usize) noretu |
| 23 | 23 | const std = @import("std"); |
| 24 | 24 | |
| 25 | 25 | // run |
| 26 | // backend=stage2,llvm | |
| 26 | // backend=selfhosted,llvm | |
| 27 | 27 | // target=x86_64-linux,aarch64-linux |
test/cases/safety/slicing null C pointer - runtime len.zig	+1-1| ... | ... | @@ -17,5 +17,5 @@ pub fn main() !void { |
| 17 | 17 | return error.TestFailed; |
| 18 | 18 | } |
| 19 | 19 | // run |
| 20 | // backend=stage2,llvm | |
| 20 | // backend=selfhosted,llvm | |
| 21 | 21 | // target=x86_64-linux,aarch64-linux |
test/cases/safety/slicing null C pointer.zig	+1-1| ... | ... | @@ -16,5 +16,5 @@ pub fn main() !void { |
| 16 | 16 | return error.TestFailed; |
| 17 | 17 | } |
| 18 | 18 | // run |
| 19 | // backend=stage2,llvm | |
| 19 | // backend=selfhosted,llvm | |
| 20 | 20 | // target=x86_64-linux,aarch64-linux |
test/cases/safety/switch else on corrupt enum value - one prong.zig	+1-1| ... | ... | @@ -20,5 +20,5 @@ pub fn main() !void { |
| 20 | 20 | } |
| 21 | 21 | } |
| 22 | 22 | // run |
| 23 | // backend=stage2,llvm | |
| 23 | // backend=selfhosted,llvm | |
| 24 | 24 | // target=x86_64-linux |
test/cases/safety/switch else on corrupt enum value - union.zig	+1-1| ... | ... | @@ -25,5 +25,5 @@ pub fn main() !void { |
| 25 | 25 | } |
| 26 | 26 | } |
| 27 | 27 | // run |
| 28 | // backend=stage2,llvm | |
| 28 | // backend=selfhosted,llvm | |
| 29 | 29 | // target=x86_64-linux |
test/cases/safety/switch else on corrupt enum value.zig	+1-1| ... | ... | @@ -19,5 +19,5 @@ pub fn main() !void { |
| 19 | 19 | } |
| 20 | 20 | } |
| 21 | 21 | // run |
| 22 | // backend=stage2,llvm | |
| 22 | // backend=selfhosted,llvm | |
| 23 | 23 | // target=x86_64-linux |
test/cases/safety/switch on corrupted enum value.zig	+1-1| ... | ... | @@ -23,5 +23,5 @@ pub fn main() !void { |
| 23 | 23 | } |
| 24 | 24 | |
| 25 | 25 | // run |
| 26 | // backend=stage2,llvm | |
| 26 | // backend=selfhosted,llvm | |
| 27 | 27 | // target=x86_64-linux,aarch64-linux |
test/cases/safety/switch on corrupted union value.zig	+1-1| ... | ... | @@ -23,5 +23,5 @@ pub fn main() !void { |
| 23 | 23 | } |
| 24 | 24 | |
| 25 | 25 | // run |
| 26 | // backend=stage2,llvm | |
| 26 | // backend=selfhosted,llvm | |
| 27 | 27 | // target=x86_64-linux |
test/cases/safety/truncating vector cast.zig	+1-1| ... | ... | @@ -17,5 +17,5 @@ pub fn main() !void { |
| 17 | 17 | } |
| 18 | 18 | |
| 19 | 19 | // run |
| 20 | // backend=stage2,llvm | |
| 20 | // backend=selfhosted,llvm | |
| 21 | 21 | // target=x86_64-linux |
test/cases/safety/unreachable.zig+1-1| ... | ... | @@ -11,5 +11,5 @@ pub fn main() !void { |
| 11 | 11 | unreachable; |
| 12 | 12 | } |
| 13 | 13 | // run |
| 14 | // backend=stage2,llvm | |
| 14 | // backend=selfhosted,llvm | |
| 15 | 15 | // target=x86_64-linux,aarch64-linux |
test/cases/safety/unsigned integer not fitting in cast to signed integer - same bit count.zig	+1-1| ... | ... | @@ -15,5 +15,5 @@ pub fn main() !void { |
| 15 | 15 | return error.TestFailed; |
| 16 | 16 | } |
| 17 | 17 | // run |
| 18 | // backend=stage2,llvm | |
| 18 | // backend=selfhosted,llvm | |
| 19 | 19 | // target=x86_64-linux |
test/cases/safety/unsigned shift left overflow.zig	+1-1| ... | ... | @@ -17,5 +17,5 @@ fn shl(a: u16, b: u4) u16 { |
| 17 | 17 | return @shlExact(a, b); |
| 18 | 18 | } |
| 19 | 19 | // run |
| 20 | // backend=stage2,llvm | |
| 20 | // backend=selfhosted,llvm | |
| 21 | 21 | // target=x86_64-linux |
test/cases/safety/unsigned shift right overflow.zig	+1-1| ... | ... | @@ -17,5 +17,5 @@ fn shr(a: u16, b: u4) u16 { |
| 17 | 17 | return @shrExact(a, b); |
| 18 | 18 | } |
| 19 | 19 | // run |
| 20 | // backend=stage2,llvm | |
| 20 | // backend=selfhosted,llvm | |
| 21 | 21 | // target=x86_64-linux,aarch64-linux |
test/cases/safety/unsigned-signed vector cast.zig	+1-1| ... | ... | @@ -17,5 +17,5 @@ pub fn main() !void { |
| 17 | 17 | } |
| 18 | 18 | |
| 19 | 19 | // run |
| 20 | // backend=stage2,llvm | |
| 20 | // backend=selfhosted,llvm | |
| 21 | 21 | // target=x86_64-linux |
test/cases/safety/unwrap error switch.zig	+1-1| ... | ... | @@ -17,5 +17,5 @@ fn bar() !void { |
| 17 | 17 | return error.Whatever; |
| 18 | 18 | } |
| 19 | 19 | // run |
| 20 | // backend=stage2,llvm | |
| 20 | // backend=selfhosted,llvm | |
| 21 | 21 | // target=x86_64-linux,aarch64-linux |
test/cases/safety/unwrap error.zig	+1-1| ... | ... | @@ -15,5 +15,5 @@ fn bar() !void { |
| 15 | 15 | return error.Whatever; |
| 16 | 16 | } |
| 17 | 17 | // run |
| 18 | // backend=stage2,llvm | |
| 18 | // backend=selfhosted,llvm | |
| 19 | 19 | // target=x86_64-linux,aarch64-linux |
test/cases/safety/value does not fit in shortening cast - u0.zig	+1-1| ... | ... | @@ -17,5 +17,5 @@ fn shorten_cast(x: u8) u0 { |
| 17 | 17 | return @intCast(x); |
| 18 | 18 | } |
| 19 | 19 | // run |
| 20 | // backend=stage2,llvm | |
| 20 | // backend=selfhosted,llvm | |
| 21 | 21 | // target=x86_64-linux,aarch64-linux |
test/cases/safety/value does not fit in shortening cast.zig	+1-1| ... | ... | @@ -17,5 +17,5 @@ fn shorten_cast(x: i32) i8 { |
| 17 | 17 | return @intCast(x); |
| 18 | 18 | } |
| 19 | 19 | // run |
| 20 | // backend=stage2,llvm | |
| 20 | // backend=selfhosted,llvm | |
| 21 | 21 | // target=x86_64-linux,aarch64-linux |
test/cases/safety/vector integer addition overflow.zig	+1-1| ... | ... | @@ -18,5 +18,5 @@ fn add(a: @Vector(4, i32), b: @Vector(4, i32)) @Vector(4, i32) { |
| 18 | 18 | return a + b; |
| 19 | 19 | } |
| 20 | 20 | // run |
| 21 | // backend=stage2,llvm | |
| 21 | // backend=selfhosted,llvm | |
| 22 | 22 | // target=x86_64-linux |
test/cases/safety/vector integer multiplication overflow.zig	+1-1| ... | ... | @@ -18,5 +18,5 @@ fn mul(a: @Vector(4, u8), b: @Vector(4, u8)) @Vector(4, u8) { |
| 18 | 18 | return a * b; |
| 19 | 19 | } |
| 20 | 20 | // run |
| 21 | // backend=stage2,llvm | |
| 21 | // backend=selfhosted,llvm | |
| 22 | 22 | // target=x86_64-linux |
test/cases/safety/vector integer negation overflow.zig	+1-1| ... | ... | @@ -18,5 +18,5 @@ fn neg(a: @Vector(4, i16)) @Vector(4, i16) { |
| 18 | 18 | return -a; |
| 19 | 19 | } |
| 20 | 20 | // run |
| 21 | // backend=stage2,llvm | |
| 21 | // backend=selfhosted,llvm | |
| 22 | 22 | // target=x86_64-linux |
test/cases/safety/vector integer subtraction overflow.zig	+1-1| ... | ... | @@ -18,5 +18,5 @@ fn sub(a: @Vector(4, u32), b: @Vector(4, u32)) @Vector(4, u32) { |
| 18 | 18 | return a - b; |
| 19 | 19 | } |
| 20 | 20 | // run |
| 21 | // backend=stage2,llvm | |
| 21 | // backend=selfhosted,llvm | |
| 22 | 22 | // target=x86_64-linux |
test/cases/safety/zero casted to error.zig	+1-1| ... | ... | @@ -15,5 +15,5 @@ fn bar(x: u16) anyerror { |
| 15 | 15 | return @errorFromInt(x); |
| 16 | 16 | } |
| 17 | 17 | // run |
| 18 | // backend=stage2,llvm | |
| 18 | // backend=selfhosted,llvm | |
| 19 | 19 | // target=x86_64-linux,aarch64-linux |
test/cases/spirv_mergable_pointers.zig+1-1| ... | ... | @@ -12,6 +12,6 @@ export fn a() void { |
| 12 | 12 | |
| 13 | 13 | // compile |
| 14 | 14 | // output_mode=Obj |
| 15 | // backend=stage2 | |
| 15 | // backend=selfhosted | |
| 16 | 16 | // target=spirv64-vulkan |
| 17 | 17 | // emit_bin=false |
test/cases/taking_pointer_of_global_tagged_union.zig+1-1| ... | ... | @@ -22,5 +22,5 @@ pub fn main() !void { |
| 22 | 22 | } |
| 23 | 23 | |
| 24 | 24 | // run |
| 25 | // backend=stage2,llvm | |
| 25 | // backend=selfhosted,llvm | |
| 26 | 26 | // target=x86_64-linux |
test/cases/union_unresolved_layout.zig+1-1| ... | ... | @@ -11,5 +11,5 @@ pub fn main() !void { |
| 11 | 11 | } |
| 12 | 12 | |
| 13 | 13 | // run |
| 14 | // backend=stage2,llvm | |
| 14 | // backend=selfhosted,llvm | |
| 15 | 15 | // |
test/src/Cases.zig+20-8| ... | ... | @@ -26,8 +26,10 @@ pub const DepModule = struct { |
| 26 | 26 | }; |
| 27 | 27 | |
| 28 | 28 | pub const Backend = enum { |
| 29 | /// Test does not care which backend is used; compiler gets to pick the default. | |
| 30 | auto, | |
| 29 | 31 | stage1, |
| 30 | stage2, | |
| 32 | selfhosted, | |
| 31 | 33 | llvm, |
| 32 | 34 | }; |
| 33 | 35 | |
| ... | ... | @@ -75,7 +77,7 @@ pub const Case = struct { |
| 75 | 77 | emit_h: bool = false, |
| 76 | 78 | is_test: bool = false, |
| 77 | 79 | expect_exact: bool = false, |
| 78 | backend: Backend = .stage2, | |
| 80 | backend: Backend = .auto, | |
| 79 | 81 | link_libc: bool = false, |
| 80 | 82 | pic: ?bool = null, |
| 81 | 83 | pie: ?bool = null, |
| ... | ... | @@ -423,13 +425,13 @@ fn addFromDirInner( |
| 423 | 425 | const resolved_target = b.resolveTargetQuery(target_query); |
| 424 | 426 | const target = &resolved_target.result; |
| 425 | 427 | for (backends) |backend| { |
| 426 | if (backend == .stage2 and | |
| 428 | if (backend == .selfhosted and | |
| 427 | 429 | target.cpu.arch != .aarch64 and target.cpu.arch != .wasm32 and target.cpu.arch != .x86_64 and target.cpu.arch != .spirv64) |
| 428 | 430 | { |
| 429 | 431 | // Other backends don't support new liveness format |
| 430 | 432 | continue; |
| 431 | 433 | } |
| 432 | if (backend == .stage2 and target.os.tag == .macos and | |
| 434 | if (backend == .selfhosted and target.os.tag == .macos and | |
| 433 | 435 | target.cpu.arch == .x86_64 and builtin.cpu.arch == .aarch64) |
| 434 | 436 | { |
| 435 | 437 | // Rosetta has issues with ZLD |
| ... | ... | @@ -618,7 +620,16 @@ pub fn lowerToBuildSteps( |
| 618 | 620 | if (options.skip_macos and case.target.query.os_tag == .macos) continue; |
| 619 | 621 | if (options.skip_linux and case.target.query.os_tag == .linux) continue; |
| 620 | 622 | |
| 621 | const would_use_llvm = @import("../tests.zig").wouldUseLlvm(case.backend == .llvm, case.target.query, case.optimize_mode); | |
| 623 | const would_use_llvm = @import("../tests.zig").wouldUseLlvm( | |
| 624 | switch (case.backend) { | |
| 625 | .auto => null, | |
| 626 | .stage1 => continue, | |
| 627 | .selfhosted => false, | |
| 628 | .llvm => true, | |
| 629 | }, | |
| 630 | case.target.query, | |
| 631 | case.optimize_mode, | |
| 632 | ); | |
| 622 | 633 | if (options.skip_llvm and would_use_llvm) continue; |
| 623 | 634 | |
| 624 | 635 | const triple_txt = case.target.query.zigTriple(b.allocator) catch @panic("OOM"); |
| ... | ... | @@ -687,8 +698,9 @@ pub fn lowerToBuildSteps( |
| 687 | 698 | if (case.pie) |pie| artifact.pie = pie; |
| 688 | 699 | |
| 689 | 700 | switch (case.backend) { |
| 701 | .auto => {}, | |
| 690 | 702 | .stage1 => continue, |
| 691 | .stage2 => { | |
| 703 | .selfhosted => { | |
| 692 | 704 | artifact.use_llvm = false; |
| 693 | 705 | artifact.use_lld = false; |
| 694 | 706 | }, |
| ... | ... | @@ -767,7 +779,7 @@ const TestManifestConfigDefaults = struct { |
| 767 | 779 | /// Asserts if the key doesn't exist - yep, it's an oversight alright. |
| 768 | 780 | fn get(@"type": TestManifest.Type, key: []const u8) []const u8 { |
| 769 | 781 | if (std.mem.eql(u8, key, "backend")) { |
| 770 | return "stage2"; | |
| 782 | return "auto"; | |
| 771 | 783 | } else if (std.mem.eql(u8, key, "target")) { |
| 772 | 784 | if (@"type" == .@"error" or @"type" == .translate_c or @"type" == .run_translated_c) { |
| 773 | 785 | return "native"; |
| ... | ... | @@ -824,7 +836,7 @@ const TestManifestConfigDefaults = struct { |
| 824 | 836 | /// (see https://github.com/ziglang/zig/issues/11288) |
| 825 | 837 | /// |
| 826 | 838 | /// error |
| 827 | /// backend=stage1,stage2 | |
| 839 | /// backend=selfhosted,llvm | |
| 828 | 840 | /// output_mode=exe |
| 829 | 841 | /// |
| 830 | 842 | /// :3:19: error: foo |