Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
refactor(transformer/arrow-functions): do not inline non-trivial visi…
…tor method (#8321) Follow-on after #8024. Don't inline `visit_statements` visitor method. This visitor is not so small, and always executes unconditionally. The compiler can decide whether to inline it or not. Where `#[inline]` is really valuable is: 1. Where the function is tiny so the cost of moving it into the caller is small. and 2. The function gets called a lot e.g. `visit_expression`, `visit_statement`, `visit_identifier_reference`. 3. Most commonly the function checks something and exits "nothing to do here". e.g. `visit_expression` where you only need to transform a particular type of `Expression`.
- Loading branch information