Skip to content
  • jrfnl's avatar
    Performance: use FQN for all global functions · db5ea619
    jrfnl authored
    Functions in PHP are namespaced as well, however, when PHP cannot find the function in the namespace, it will fall through to the global namespace.
    
    The step to first check within the namespace can be skipped by either using `use function ...` (PHP 5.6+) or by prefixing the function name with a `\`.
    
    As PHPCompatibility uses a global functions throughout, a little performance gain can be archived by using the FQN for functions.
    
    This PR implements this throughout the codebase.
    
    This was previously already done for constants (783) and for the functions which benefit from PHP 8 opcodes (784).
    db5ea619