-
Notifications
You must be signed in to change notification settings - Fork 1.4k
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
Unclosed string problem #505
Comments
Good report. The beautifier doesn't parse the whole file beforehand, so it doesn't know that you left a quote out until at least the end of that line. What behavior would you like to see in this case? Should it simply not format the rest of the input? Pass it through unchanged? What about other situations? Missing parenthesis or other delimiter? I just want to understand your perspective. |
Previously I'm working with eclipse. |
Yes, those systems fully parse the whole file and report syntactic errors. The beautifier does not (see #200). Still, we should be able to figure out that the string is unterminated and limit the misformatting. |
For string, if the close character is not found until end of line, it's marked as error and parsing process can continue guess the rest of stream. |
Agree, this should be a straightforward fix. |
Just remove second quote on 'a' and you will have weird format on 'b':
Even after you revise 'a back into 'a', second name assign stale in weird like below:
My problems getting worse when there is very much lines after incorrect string formatting.
The text was updated successfully, but these errors were encountered: