Hi Tim, 

I posted this in the other thread, but I'm not sure it got through, so I'll 
repost here; apologies if both show up at once.

On 31 July 2026 18:12:01 BST, "Tim Düsterhus" <[email protected]> wrote:
>> Without giving it detailed thought, I believe “Namespaced function, Autoload 
>> namespaced function, Global fallback” (i.e. swap steps 2 and 3) would result 
>> in much more predictable semantics already - the global fallback would work 
>> just as before, it just wouldn't have autoloading support.


Semantically, that makes most sense, but it leads to terrible performance for 
the global fallback case, unless there's some way to avoid multiple checks for 
the same namespaced function. That's why we keep going round in circles on the 
whole issue. 

I think Michael's "namespace autoloader" idea is a much cleaner way forward - 
it avoids the fallback issue without creating lots of extra special cases, and 
in reality "load a file with all functions for namespace Foo\Bar" is likely to 
be more common than "load a file which specifically defines function 
Foo\Bar\baz()".

Regards,

Rowan Tommins
[IMSoP]

Reply via email to