aboutsummaryrefslogtreecommitdiff
path: root/src/check_stmt.cpp
diff options
context:
space:
mode:
authorgingerBill <bill@gingerbill.org>2021-04-19 15:46:12 +0100
committergingerBill <bill@gingerbill.org>2021-04-19 15:46:12 +0100
commit36125696240469d0adcb78caa8093f581debdcb2 (patch)
treeca7ca09a62651908213429a1a7cd45ea7c0c5faf /src/check_stmt.cpp
parentc83d13d0cbbf204a045a379c74bffc4d5bcfb53c (diff)
Allow casting of `#optional_ok` call expressions
Diffstat (limited to 'src/check_stmt.cpp')
-rw-r--r--src/check_stmt.cpp6
1 files changed, 3 insertions, 3 deletions
diff --git a/src/check_stmt.cpp b/src/check_stmt.cpp
index 9d02d003d..0ce0ff6a0 100644
--- a/src/check_stmt.cpp
+++ b/src/check_stmt.cpp
@@ -1751,7 +1751,7 @@ void check_stmt_internal(CheckerContext *ctx, Ast *node, u32 flags) {
Type *cond_type = t->Tuple.variables[count-1]->type;
if (!is_type_boolean(cond_type)) {
gbString s = type_to_string(cond_type);
- error(operand.expr, "The final type of %td-valued tuple must be a boolean, got %s", count, s);
+ error(operand.expr, "The final type of %td-valued expression must be a boolean, got %s", count, s);
gb_string_free(s);
break;
}
@@ -1762,14 +1762,14 @@ void check_stmt_internal(CheckerContext *ctx, Ast *node, u32 flags) {
if (rs->vals.count > 1 && rs->vals[1] != nullptr && count < 3) {
gbString s = type_to_string(t);
- error(operand.expr, "Expected a 3-value tuple on the rhs, got (%s)", s);
+ error(operand.expr, "Expected a 3-valued expression on the rhs, got (%s)", s);
gb_string_free(s);
break;
}
if (rs->vals.count > 0 && rs->vals[0] != nullptr && count < 2) {
gbString s = type_to_string(t);
- error(operand.expr, "Expected at least a 2-values tuple on the rhs, got (%s)", s);
+ error(operand.expr, "Expected at least a 2-valued expression on the rhs, got (%s)", s);
gb_string_free(s);
break;
}