FunctionCallRefiner
Refines a WalkedFunctionCall, which is a context-free syntactical element extracted from a function call in a source code, into a processed, context-aware FunctionCallNode.
This refiner also handles function chaining, which is represented by a linked list in the WalkedFunctionCall structure, but is a tree in the FunctionCallNode structure.
Example:
Source code:
.foo {x}::bar {y}Walked function call:
.foo {x}->.bar {y}Refinement:
.bar {.foo {x}} {y}
Parameters
context of the function call
walked function call to refine
whether the function call is a block
if available, the source code of the whole function call
if available, the range of the function call in the source code
initial arguments to add to the function call (used internally for chaining)
Constructors
Functions
Refines the walked function call into a FunctionCallNode.