For example I have class A in file a.php
namespace Path\To;
class A {
const SOME_VAR = 'value';
// many functions
}
And I have class B in file b.php
use Path\To\A;
class B {
public function foo() {
$i = 1;
$i = 2;
$i = 3;
// other code
$someVar = A::SOME_VAR;
}
// other functions
}
Which time in executing function foo
constant variable SOME_VAR
loads in RAM. On first line of function foo or on line $someVar = A::SOME_VAR;
or line use Path\to\A;
or elsewhere?