mirror of
https://github.com/odin-lang/Odin.git
synced 2026-10-09 14:22:18 -04:00
Make diverging or_else inherit lhs type
This commit is contained in:
1 parent
e276ce552b
commit
aa53466cb6
1 file changed
+1
@@ -9899,6 +9899,7 @@ gb_internal ExprKind check_or_else_expr(CheckerContext *c, Operand *o, Ast *node
|
||||
if (is_diverging_expr(y.expr)) {
|
||||
// Allow
|
||||
y.mode = Addressing_Value;
|
||||
y.type = x.type;
|
||||
y_is_diverging = true;
|
||||
} else {
|
||||
error_operand_no_value(&y);
|
||||
|
||||
Reference in new issue
Block a user