You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Some research needs to be done on how to best encode these
I'm actually not 100% on what the best implementation approach should be here. There are no native logical operators in wasm, probably because it's just all bitwise &s and |s. Problem is, logical operators have a different semantic from binary ops in most language.
const a: i32 = maybeThis() || maybeThat(); encoded into a bitwise or is not enough here. Probably means that logical operators need to be encoded as blocks that return a value.
Acceptance Criteria
Support binary logical operators
Logical ops should return one of the operands
Support short-circuiting
Test the world
Tests pass
The text was updated successfully, but these errors were encountered:
Goal
We should have logical operator support
Overview
Some research needs to be done on how to best encode these
I'm actually not 100% on what the best implementation approach should be here. There are no native logical operators in wasm, probably because it's just all bitwise
&
s and|
s. Problem is, logical operators have a different semantic from binary ops in most language.const a: i32 = maybeThis() || maybeThat();
encoded into a bitwise or is not enough here. Probably means that logical operators need to be encoded as blocks that return a value.Acceptance Criteria
The text was updated successfully, but these errors were encountered: