dillon1000/react

Commit

[compiler] Fix failing Rust compiler test case for todo-locally-require-fbt (#36767)

Two fundamental changes (plus a lot of formatting that got mixed in :/
): Modify how we determine if a local binding exists for the case where
the scope is extracted from a function, rather than a module, which is
the case for snap tests. And, loosen the rust port tester to allow debug
output to be printed from one compiler or another as long as both sides
error in the same phase with the same error message (basically, the rust
port emits debug information before throwing an error, whereas the TS
version does one or the other -- but it's not actually a real
difference).

With this change and loosening, the Rust compiler conforms on the
todo-locally-require-fbt case.

---------

Co-authored-by: mvitousek <[email protected]>
Browse files
Changed paths2 files
First-parent comparison
M compiler/crates/react_compiler_lowering/src/hir_builder.rs ModifiedM compiler/scripts/test-rust-port.ts Modified
Patch

Files changed

Rendering syntax-highlighted changes…