Support ES5 Strict Mode, and fix logical/conditional operators
- Improve compiler performance (approx 20%)
- Fix issues related to the generation of nested FunctionDeclarations in ES5-Strict mode
- Re-implement mapLogicalOps & mapCondOps to generate correct code for expressions like
a || b && await c
. Previous version produced code that wouldn't run in some circumstances - Allow the option
{log:false}
instead of a no-op function - Correctly place directives at the top of the Program/function when hoisting declarations.
Thanks to https://github.com/epoberezkin for the additional test cases and enhancements