tokay-lang / tokay

Tokay is a programming language designed for ad-hoc parsing, inspired by awk.
https://tokay.dev
MIT License
239 stars 7 forks source link

`"x".upper.replace("y")` throws `"Method 'method_replace' not found"` #113

Open phorward opened 1 year ago

phorward commented 1 year ago

By design, this issue points to an inconsistency, as the first method isn't called, and holds a reference to the method call.

This fails:

>>> "Glasflügel".upper.replace("L")
Line 1, column 20: Method 'method_replace' not found

This works:

>>> "Glasflügel".upper().replace("L")
"GASFÜGE"

Such a case should only appear when the #17 *deref-operator is being used.