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

Incorrect handling of multistr lines with closing quote on empty line #1532

Closed
AndrewRayCode opened this issue Feb 16, 2014 · 1 comment · Fixed by #2264
Closed

Incorrect handling of multistr lines with closing quote on empty line #1532

AndrewRayCode opened this issue Feb 16, 2014 · 1 comment · Fixed by #2264

Comments

@AndrewRayCode
Copy link

test = "closing quote on next line\
";

Gives erroneous warning "Unclosed string."

Added it to the strings.js file. I've been poking around the lexer but don't have high hopes for quickly finding the issue, although it might be related to nextLine()

AndrewRayCode added a commit to AndrewRayCode/jshint that referenced this issue Feb 16, 2014
@AndrewRayCode
Copy link
Author

It looks like it thinks the closing quote is escaped by the \ ...

jacksonmj added a commit to jacksonmj/jshint that referenced this issue Mar 18, 2015
…st character after a newline

Previously, the end-of-line loop was immediately followed by the non-quote character code. This
meant that the first character after an EOL was always treated as a non-quote character.

Control flow now returns to the quote character check in the while loop condition immediately
after each EOL or character has been handled, so that this check also runs for the first character
on a line.

Closes jshint#1532. (This commit includes the test case provided in jshint#1532 by DelvarWorld.)
Closes jshint#1319.
jugglinmike pushed a commit to jugglinmike/jshint that referenced this issue Apr 12, 2015
…st character after a newline

Previously, the end-of-line loop was immediately followed by the non-quote character code. This
meant that the first character after an EOL was always treated as a non-quote character.

Control flow now returns to the quote character check in the while loop condition immediately
after each EOL or character has been handled, so that this check also runs for the first character
on a line.

Closes jshint#1532. (This commit includes the test case provided in jshint#1532 by DelvarWorld.)
Closes jshint#1319.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
1 participant