Probably a trivial question, but in which order does Exception::getTrace
return calls? Most recent first or last? I'd like to know before I implement my error handler.
BenTheDesigner
Probably a trivial question, but in which order does Exception::getTrace
return calls? Most recent first or last? I'd like to know before I implement my error handler.
BenTheDesigner
Why don't you test it yourself?
function NestedFunc() {
throw new Exception("test");
}
function FunctionAbc() {
NestedFunc();
}
try {
FunctionAbc();
} catch (Exception $e) {
var_dump($e->getTrace());
}