aboutsummaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
authorgingerBill <bill@gingerbill.org>2022-07-19 16:17:23 +0100
committergingerBill <bill@gingerbill.org>2022-07-19 16:17:23 +0100
commit3db3047f47ddda7f99dc7c481e368cff68db4aaf (patch)
tree81ff1f8579781d987a9c470545f0a01c06bfe772 /src
parent7420fbd95b1130e3b2e7eaf52c56302a6e1f3b31 (diff)
Minor improvements
Diffstat (limited to 'src')
-rw-r--r--src/check_type.cpp4
1 files changed, 3 insertions, 1 deletions
diff --git a/src/check_type.cpp b/src/check_type.cpp
index cd4b43fab..741385e29 100644
--- a/src/check_type.cpp
+++ b/src/check_type.cpp
@@ -1345,7 +1345,9 @@ ParameterValue handle_parameter_value(CheckerContext *ctx, Type *in_type, Type *
param_value.kind = ParameterValue_Constant;
param_value.value = o.value;
} else {
- error(expr, "Default parameter must be a constant, %d", o.mode);
+ gbString s = expr_to_string(o.expr);
+ error(expr, "Default parameter must be a constant, got %s", s);
+ gb_string_free(s);
}
}
} else {