diff options
| author | Vexu <git@vexu.eu> | 2020-09-04 21:41:34 +0300 |
|---|---|---|
| committer | Vexu <git@vexu.eu> | 2020-09-04 22:02:39 +0300 |
| commit | 6b2f4fd20d3c85e5db592f76dea8e56da54e9211 (patch) | |
| tree | 66751baec2774d8fbe428284bc1d01ad0d8a821c /src/ir.cpp | |
| parent | 88724b2a89157ecc3a8eea03aa0f8a6b66829915 (diff) | |
| download | zig-6b2f4fd20d3c85e5db592f76dea8e56da54e9211.tar.gz zig-6b2f4fd20d3c85e5db592f76dea8e56da54e9211.zip | |
langref: atomic ops are allowed on pointers
Closes #6217
Diffstat (limited to 'src/ir.cpp')
| -rw-r--r-- | src/ir.cpp | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/src/ir.cpp b/src/ir.cpp index 9d5814ab6f..efc9cb6707 100644 --- a/src/ir.cpp +++ b/src/ir.cpp @@ -26752,7 +26752,7 @@ static IrInstGen *ir_analyze_instruction_cmpxchg(IrAnalyze *ira, IrInstSrcCmpxch if (operand_type->id == ZigTypeIdFloat) { ir_add_error(ira, &instruction->type_value->child->base, - buf_sprintf("expected integer, enum or pointer type, found '%s'", buf_ptr(&operand_type->name))); + buf_sprintf("expected bool, integer, enum or pointer type, found '%s'", buf_ptr(&operand_type->name))); return ira->codegen->invalid_inst_gen; } @@ -30407,7 +30407,7 @@ static ZigType *ir_resolve_atomic_operand_type(IrAnalyze *ira, IrInstGen *op) { return ira->codegen->builtin_types.entry_invalid; if (operand_ptr_type == nullptr) { ir_add_error(ira, &op->base, - buf_sprintf("expected integer, float, enum or pointer type, found '%s'", + buf_sprintf("expected bool, integer, float, enum or pointer type, found '%s'", buf_ptr(&operand_type->name))); return ira->codegen->builtin_types.entry_invalid; } |
