Hello George,

I'm not sure I'm 100% correct but I think that this RFC still allows to
call different functions for the same code, just not in the same run.

Consider this pseudocode:

//- funcs.php

namespace My;

function myfunc(...) { ... }
function array_map(...) { ... }

//- code1.php

namespace My;

myfunc(1); // autoload triggered
// bonus points if it's a different file or some obscure method
array_map(strlen(...), []); // My\array_map

//- code2.php

namespace My;

// no prior autoload
array_map(strlen(...), []); // global array_map

And if I understand the current order of execution correctly, here is a
more extreme example:

//- moreextreme.php

namespace My;

if (some_random()) {
  array_map('My\myfunc', []); // global array_map
} else {
  array_map(myfunc(...), []); // My\array_map
}

-- 
Anton

--
PHP Internals - PHP Runtime Development Mailing List
To unsubscribe, visit: https://www.php.net/unsub.php

Reply via email to