Skip to content

defer looking up function calls until after parsing #387

@trillllian

Description

@trillllian

math_ast_function_call looks up the function name in its constructor. this has the unfortunate effect that user function definitions can't refer to userfuncs defined in the future (which is a regression relative to the old parser)

where do i defer this lookup to though??? redo it on every call to getlen/haslabel/evaluate? make it cache the result somewhere? (all the ast_node functions are marked const, but i guess i can delete the consts.)

probably fine to redo it, it's two hashmap lookups in total

Metadata

Metadata

Assignees

No one assigned

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions