Shared helpers for smell checks including loop detection, statement pairs, and callbacks.
Summary
Functions
Returns top-level statements from a function body.
Extracts the callback fn body nodes from an Enum call.
Returns true if node is inside an accumulator-carrying loop (reduce/scan).
Returns true if node is inside a loop body (reduce/map/for/recursion).
Returns true if the function contains a self-recursive call.
Returns adjacent top-level statement pairs from a function body.
Functions
Returns top-level statements from a function body.
Extracts the callback fn body nodes from an Enum call.
Returns true if node is inside an accumulator-carrying loop (reduce/scan).
Returns true if node is inside a loop body (reduce/map/for/recursion).
Returns true if the function contains a self-recursive call.
Returns adjacent top-level statement pairs from a function body.