Skip to content

Commit 9ac2311

Browse files
committed
Fix an infinite loop in Crystal heredoc tokenizing
FIX: Fix an infinite loop when tokenizing heredoc strings in the Crystal mode. Closes codemirror/codemirror5#7092
1 parent 48c56cf commit 9ac2311

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

mode/crystal.js

+1-1
Original file line numberDiff line numberDiff line change
@@ -365,7 +365,7 @@ function tokenHereDoc(phrase, embed) {
365365
return "string";
366366
}
367367

368-
escaped = embed && stream.next() == "\\";
368+
escaped = stream.next() == "\\" && embed;
369369
} else {
370370
stream.next();
371371
escaped = false;

0 commit comments

Comments
 (0)