dg / bypass-finals

Removes `final` and `readonly` keywords from source code on-the-fly and allows mocking of final methods and classes. It can be used together with any test tool such as PHPUnit or Mockery.
Other
487 stars 30 forks source link

allow inheritance by using static instead of self and making properti… #25

Closed idimsh closed 4 years ago

idimsh commented 4 years ago

allow inheritance by using static instead of self and making properties protected. Method ::removeFinals() is receiving the path because it might be needed in a child class that will catch parse errors in token_get_all() and report the failed file.

dg commented 4 years ago

I don't like inheritance here, but I Implemented catching parse error directly in removeFinals()