dillon1000/react
Commit
Browse files TryStatement: partial lowering
Implements the core lowering logic for try/catch: * Inside of the `try` block, we use the new HIRBuilder mode to wrap every instruction in a separate basic block with a maybe-throw terminal * We emit a 'try' terminal for the try/catch itself For basic examples this already works correctly. But we don't handle catch clause params yet.
Changed paths9 files
First-parent comparisoncompiler/packages/babel-plugin-react-forget/src/HIR/BuildHIR.ts ModifiedM compiler/packages/babel-plugin-react-forget/src/HIR/HIRBuilder.ts ModifiedA compiler/packages/babel-plugin-react-forget/src/__tests__/fixtures/compiler/try-catch-mutate-outer-value.expect.md AddedA compiler/packages/babel-plugin-react-forget/src/__tests__/fixtures/compiler/try-catch-mutate-outer-value.js AddedA compiler/packages/babel-plugin-react-forget/src/__tests__/fixtures/compiler/try-catch-within-mutable-range.expect.md AddedA compiler/packages/babel-plugin-react-forget/src/__tests__/fixtures/compiler/try-catch-within-mutable-range.js AddedA compiler/packages/babel-plugin-react-forget/src/__tests__/fixtures/compiler/try-catch.expect.md AddedA compiler/packages/babel-plugin-react-forget/src/__tests__/fixtures/compiler/try-catch.js AddedM compiler/packages/sprout/src/SproutTodoFilter.ts ModifiedPatch
Files changed
Rendering syntax-highlighted changes…