scalar_objects icon indicating copy to clipboard operation
scalar_objects copied to clipboard

RFC probability

Open abramchikd opened this issue 2 years ago • 2 comments

Hey! Is there any chance that this will be implemented as and RFC?

I can also think of another method of achieving such functionality: allowing any function to be called as an extension method. If the left operand of $a->callSomething() is a primitive type or the method on object does not exist and __call is not implemented, then try to execute callSomething as a function and pass $a as a first parameter. Are there any drawbacks of implementing it this way? I tried to do it myself, but php src seems to be too complicated for me

abramchikd avatar Aug 15 '23 12:08 abramchikd

@nikic

abramchikd avatar Aug 15 '23 12:08 abramchikd

Not only register methods, but properties too.

rodrigoslayertech avatar Jul 29 '24 23:07 rodrigoslayertech