Skip to content

Commit

Permalink
Refactor: split up maybe_hoist_and_create_proxy (and cache variant)
Browse files Browse the repository at this point in the history
The functions `maybe_hoist_and_create_proxy` and
`maybe_hoist_and_create_proxy_to_cache` are currently declared to accept
an optional function declaration and/or an optional arrow function
expression. Most of their implementation is then forked on whether
either of those is passed in.

However, all call sites always pass in either a well-defined function
declaration or a well-defined arrow function expression, never both and
never none. Therefore it makes sense to split up those functions, and
avoid declaring the params and return types with `Option`.
  • Loading branch information
unstubbable committed Oct 2, 2024
1 parent 39e06c7 commit e956197
Showing 1 changed file with 513 additions and 502 deletions.
Loading

0 comments on commit e956197

Please sign in to comment.