aboutsummaryrefslogtreecommitdiff
path: root/core/runtime
diff options
context:
space:
mode:
authorgingerBill <bill@gingerbill.org>2021-05-05 15:22:54 +0100
committergingerBill <bill@gingerbill.org>2021-05-05 15:22:54 +0100
commit278de3a92f80e1c3f1abc3ece53db6d0bba1e393 (patch)
tree7ac454d13dd24705b25997c71a78457858cb4166 /core/runtime
parentabdf54800ec282934d7b0730d13a77b46c5c663b (diff)
Unify `AstTernaryExpr` with `AstTernaryIfExpr`
Allow for both syntaxes `x if cond else y` and `cond ? x : y` Removes the confusing semantics behind `?:` which could be `if` or `when` depending on the context.
Diffstat (limited to 'core/runtime')
-rw-r--r--core/runtime/udivmod128.odin2
1 files changed, 1 insertions, 1 deletions
diff --git a/core/runtime/udivmod128.odin b/core/runtime/udivmod128.odin
index e4b7380d3..fff856ab6 100644
--- a/core/runtime/udivmod128.odin
+++ b/core/runtime/udivmod128.odin
@@ -11,7 +11,7 @@ udivmod128 :: proc "c" (a, b: u128, rem: ^u128) -> u128 {
q, r: [2]u64 = ---, ---;
sr: u32 = 0;
- low :: ODIN_ENDIAN == "big" ? 1 : 0;
+ low :: 1 when ODIN_ENDIAN == "big" else 0;
high :: 1 - low;
U64_BITS :: 8*size_of(u64);
U128_BITS :: 8*size_of(u128);