winxed icon indicating copy to clipboard operation
winxed copied to clipboard

Quoted method calls get double quoted

Open Benabik opened this issue 13 years ago • 2 comments

obj.'!meth'() in winxed becomes obj.''!meth''() in PIR. I'm guessing that the quoted name is how I'm supposed to call methods with non-identifier names, but the extra quotes causes the PIR to be uncompilable.

Benabik avatar Apr 22 '12 20:04 Benabik

Such syntax is not really supported, even if it works in some cases. You can use the indirect call syntax:

obj.*'!meth'()

When the method is a const string, like in this case, it gets optimized to a direct call.

NotFound avatar Apr 23 '12 20:04 NotFound

I had not seen that syntax. Very useful.

However I'd argue that obj.'!meth' compiling in Winxed but doing nothing useful in the resultant PIR could be considered a bug.

Benabik avatar Apr 23 '12 23:04 Benabik