-
Notifications
You must be signed in to change notification settings - Fork 36
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
re2c 1.0.2 keeps the initial "/" at the beginning of an docblock (DCOMMENT-Token) #31
Comments
Don't concatenate result output in tests to avoid confusion. Correct parser output for the following text: ``` /** * Comment */ ``` is: ``` /** * Comment * ``` Related issues: * #31 * zephir-lang/zephir#1591 * phalcon/cphalcon#13140
Don't concatenate result output with "/" in tests to avoid confusion. Correct parser output for the following text: /** * Comment */ is: ** * Comment * Related issues: * #31 * zephir-lang/zephir#1591 * phalcon/cphalcon#13140 8ae4b82
Actually this is temporary workaround to be able try latest changes of re2c >= 1.x. Related issues: * skvadrik/re2c#197 * #31 * zephir-lang/zephir#1591 * phalcon/cphalcon#13140
@chilimatic I've prepared a patch for Zephir Parser to work with re2c >= 1.0. Could you please reinstall Zephir Parser from |
@sergeyklay yes ofc I was closely following these changes anyway. :) |
@sergeyklay works fine for me. |
Fixed in the latest stable release. Feel free to open a new issue if the problem appears again. Thank you for the report, and for helping us make Zephir Parser better. |
Hey,
relates to zephir-lang/zephir#1591
I got an issue and I cannot pinpoint it, I already solved it but it's a hack.
I am not sure if even another user is affected, it could just be my setup.
The reason why I put it here an not the zephir compiler is that I didn't want to invest more than 5 hours into reading/debugging the C/C++ and PHP code, esp since I am not used to re2c syntax.
But first things first.
versions zephir_parser / zephir (i tried different tags with zephir it doesn't matter)
lib / program versions
Error log (shortened because it's the same error for all files)
The exception.zep.c compiled source code so the error is obvious:
as you can see -> there are two slashes for the doc block comment.
The scanner keeps the beginning slash in
/**
for the DCOMMENT token which your compiler does not expect.the hacky fix is pretty simple in zephir/Compilerfile
this does not affect the behaviour and works for me locally but fixing symptoms is not a reasonable approach.
Since I cannot find anyone else complaining about this I assume this a local setup issue but it's still better to report such behavior than leave it unchecked.
Too me this is a low prio bug esp since I fixed it by a small hack in the compiler.
The text was updated successfully, but these errors were encountered: