[[FIX]] change escape-sequence handler for double quotes (\")#3566
[[FIX]] change escape-sequence handler for double quotes (\")#3566jugglinmike merged 4 commits intojshint:masterfrom
Conversation
jugglinmike
left a comment
There was a problem hiding this comment.
Thanks for the patch! Could you add a unit test which demonstrates its correctness? The file tests/unit/core.js seems like a good place for this. We could use a test case that fails in the current release of JSHint but passes with this patch applied. That will prove that this patch has the intended effect, and it will help us avoid accidentally breaking the new and improved behavior in the future.
|
Sure @jugglinmike I'll add a unit test for this. |
|
Hey @jugglinmike, I have added a unit test in the commit Also, can you please check the changes in the commit |
|
Beautiful! Thanks for the help! |
Changes the handling of escape sequence case for
\"in the lex.js file. Earlier, it converted\"into\\\", which is not the correct js equivalent for the case as it should be"only. This was causing issue #3315 as\" != "that is why jshint considers them different strings.Fixes and Closes #3315