Arquivos
hhvm/hphp/test/vm/final_method1.php.exp
T
mwilliams 951d7c0adf Fix various bugs with line numbers and classes
I found 4 separate problems, each of which broke this:
 - A hoistable class didnt generate bytecode, so the line number
   information was associated with whatever line the /next/
   bytecode corresponded to. Often there was no next bytecode,
   so we got the line number of the end of the file.
 - If there /was/ a bytecode for the defClass, the line number
   recorded for it was that of the pseudoMain, not the class
   itself; so again, it would be reported as the end of the file.
 - The parser records two sets of line numbers for a class; its
   start, and end. The end line gets associated with the bytecode.
 - There were optimized paths where we didnt setup an ActRec
   at all, resulting in either reporting the file/line of the
   require (or often a require much higher up the stack), or
   not reporting a file/line at all.

So now, we generate a nop if we would have skipped the defCls.
We override the normal line info, and set both the start and end
lines to the start. And we wrap all errors from defClass in a
temporary frame to ensure the line info is seen.

This changed the output for several of our tests. Spot checking
a couple showed they now report the same line number as zend.
2013-03-07 21:29:29 -08:00

2 linhas
102 B
Plaintext

HipHop Fatal error: Cannot override final method Foo::f() in hphp/test/vm/final_method1.php on line 7