mirror of
https://github.com/odin-lang/Odin.git
synced 2026-09-08 13:17:21 +00:00
Merge pull request #7372 from kalsprite/abs_constant_range
check_builtin: range-check the constant `abs` folds
This commit is contained in:
@@ -4612,6 +4612,11 @@ gb_internal bool check_builtin_procedure(CheckerContext *c, Operand *operand, As
|
||||
}
|
||||
GB_ASSERT(!is_type_complex_or_quaternion(operand->type));
|
||||
|
||||
if (operand->mode == Addressing_Constant) {
|
||||
operand->expr = call;
|
||||
check_is_expressible(c, operand, operand->type);
|
||||
}
|
||||
|
||||
break;
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user