Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
POC of new expression-oriented inference model for memoization within…
… control-flow (#589) * [hir] Core data types and lowering for new model * Handle more expressions, including using babel for binding resolution * test setup with pretty printing of ir * Basic codegen and improved pretty printing * avoid else block when if has no fallthrough * emit function declarations with mapped name/params * start of scope analysis * saving state pre-run * add slightly more complex example and flush out lowering/printing (jsx, new, variables) * Various improvements: * Convert logical expressions (|| and &&) to control flow, accounting for lazy evaluation semantics. * Handle expression statements * Improve printing of HIR for unsupported node kinds * Handle more cases of JSX by falling by to OtherStatement to wrap subtrees at coarse granularity. * improve HIR printing, lowering of expression statements * handle object expression printing * improve IR model for values/places along w codegen * more test cases * start of mutability inference * passable but still incorrect mutability inference * improved mutability inference, should cover most cases now * visualization of reference graph * correctly flow mutability backwards (have to actually set the capability) * separate visualization in output * consolidate on frozen/readonly/mutable capabilities * cleanup * conditional reassignment test (not quite working) * hack to output svg files for debugging * handle conditional reassignment * improve capture analysis * treat jsx as (interior) mutable; handle memberexpression lvalues * lots of comments; hook return is frozen * update main comment * inference for switch, which reveals a bug * fix yarn.lock
- Loading branch information