aboutsummaryrefslogtreecommitdiff
path: root/src/check_type.cpp
diff options
context:
space:
mode:
authorPatrick Cleavelin <patrick@uptrainsoftware.com>2024-01-27 14:12:19 -0600
committerGitHub <noreply@github.com>2024-01-27 14:12:19 -0600
commit7b9ea9eca02bf5dd295439a46ed6103a0c4a44ff (patch)
tree680a3214623087a395f66c11ddf5b6201d099bd7 /src/check_type.cpp
parent59aa05170d54edff75aed220bb1653fc369573d7 (diff)
parentda6edb3764b735a839acdd375328574833d782c1 (diff)
Merge branch 'odin-lang:master' into master
Diffstat (limited to 'src/check_type.cpp')
-rw-r--r--src/check_type.cpp3
1 files changed, 1 insertions, 2 deletions
diff --git a/src/check_type.cpp b/src/check_type.cpp
index f11418dc0..a95026711 100644
--- a/src/check_type.cpp
+++ b/src/check_type.cpp
@@ -2702,14 +2702,13 @@ gb_internal bool check_type_internal(CheckerContext *ctx, Ast *e, Type **type, T
check_expr_or_type(&c, &o, pt->type);
if (o.mode != Addressing_Invalid && o.mode != Addressing_Type) {
// NOTE(bill): call check_type_expr again to get a consistent error message
- begin_error_block();
+ ERROR_BLOCK();
elem = check_type_expr(&c, pt->type, nullptr);
if (o.mode == Addressing_Variable) {
gbString s = expr_to_string(pt->type);
error_line("\tSuggestion: ^ is used for pointer types, did you mean '&%s'?\n", s);
gb_string_free(s);
}
- end_error_block();
} else {
elem = o.type;
}