mirror of
https://github.com/facebook/react.git
synced 2025-11-01 09:12:30 +00:00
189b22171f1ffb93fa2570d1dac01c99731bba40
This currently basically lowers the code into the equivalent of ``` const vLeft = <left>; const vNull = null; const vCond = vLeft != vNull; vCond ? vLeft : <right> ``` I created a temporary `Place` to hold the `null` constant value because the binary operator in HIR accepts only `Place`s. Not sure if this is the preferred approach. Alternatives I could think of: - Allow constants as an alternative to Place? - A `NotNull` operator for `<x> != null` - Some other extension to the HIR?
Languages
JavaScript
67.1%
TypeScript
29.4%
HTML
1.5%
CSS
1.1%
C++
0.6%
Other
0.2%