From 342761e83a43d7dd79df43c00a816fa4a18abc4e Mon Sep 17 00:00:00 2001 From: gingerBill Date: Sat, 27 Mar 2021 17:21:12 +0000 Subject: Refactor record polymorphic params code for unification --- src/check_expr.cpp | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) (limited to 'src/check_expr.cpp') diff --git a/src/check_expr.cpp b/src/check_expr.cpp index 98d289aa5..20540c839 100644 --- a/src/check_expr.cpp +++ b/src/check_expr.cpp @@ -5915,7 +5915,8 @@ bool check_builtin_procedure(CheckerContext *c, Operand *operand, Ast *call, i32 i32 i = id - cast(i32)BuiltinProc__type_simple_boolean_begin; auto procedure = builtin_type_is_procs[i]; GB_ASSERT_MSG(procedure != nullptr, "%.*s", LIT(builtin_name)); - operand->value = exact_value_bool(procedure(operand->type)); + bool ok = procedure(operand->type); + operand->value = exact_value_bool(ok); } operand->mode = Addressing_Constant; operand->type = t_untyped_bool; -- cgit v1.2.3