Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Diagnostics - general tracking issue #153

Open
roblourens opened this issue Jun 13, 2017 · 2 comments
Open

Diagnostics - general tracking issue #153

roblourens opened this issue Jun 13, 2017 · 2 comments

Comments

@roblourens
Copy link
Member

The parser currently emits few diagnostics beyond general syntax errors, but it has always been the plan to walk the tree and emit more. We may want to bring it up to par with nikic/php-parser, at least.

For examples, search nikic/php-parser for emitError. e.g. in this file: https://github.com/nikic/PHP-Parser/blob/a32e3797d411590841ae06dd559ddb867d376aff/lib/PhpParser/ParserAbstract.php

@felixfbecker
Copy link

I also saw that the diagnostic code uses Reflection to get the Token name, that is very slow.

@TysonAndre
Copy link
Contributor

I also saw that the diagnostic code uses Reflection to get the Token name, that is very slow.

For tracking purposes: That was fixed in #187 (Instead of using Reflection every time, tolerant-php-parser only uses Reflection the first time, and caches that)

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

3 participants