gval icon indicating copy to clipboard operation
gval copied to clipboard

Allow variables to overload functoins

Open smyrman opened this issue 2 years ago • 2 comments

Is it be possible to configure a language so that variable names takes precedence over functions?

Use case: for a system that stores expressions, allow adding new functions to the language without breaking backwards-compatibility.

Exmaple: for a language with function sin, in the expresison sin + b -- treat sin as variable instead of a functoin if present.

smyrman avatar May 20 '22 09:05 smyrman

FYI, we do got a work-around that we find acceptable, which is to define a new language on the fly, with each function added tot the language only if there are no input variables with the same name.

smyrman avatar May 20 '22 10:05 smyrman

Hi, gval is not under activly development by paessler ag. I'm accepting merge request and try to answer the issues as an side project. As far as I know this isl only possible with replacing the Ident Expansion.

generikvault avatar May 20 '22 19:05 generikvault