Oh, I didn't mean to suggest that it automatically binds.

My second suggestion for how to achieve this does require some sort of 
automation. If you create a closure from Str::someMethod($arg1, $arg2) where 
someMethod isn't static, it should create a closure with the signature fn(Str 
$object, $arg1, $arg2), which would wrap a call to [$object, 
'someMethod]($arg1, $arg2).

However, perhaps the simplest solution, and one that could be done realtively 
easily and quickly, would be to delay the error, and allow static closures to 
bound with Closure::bind() if they represent a non-static method.

---
Best Regards,
*Ollie Read*

Reply via email to