Skip to content

Commit

Permalink
Fix lexing of empty string literals (dlang-community/SDLang-D#34).
Browse files Browse the repository at this point in the history
  • Loading branch information
s-ludwig committed Apr 5, 2016
1 parent c274081 commit 02e5369
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions source/dub/internal/sdlang/lexer.d
Expand Up @@ -546,7 +546,7 @@ class Lexer
}

advanceChar(ErrorOnEOF.Yes);
do
while(ch != '"')
{
if(ch == '\\')
{
Expand Down Expand Up @@ -582,7 +582,7 @@ class Lexer
error("Unescaped newlines are only allowed in raw strings, not regular strings.");

advanceChar(ErrorOnEOF.Yes);
} while(ch != '"');
}

updateBuf();
advanceChar(ErrorOnEOF.No); // Skip closing double-quote
Expand Down

0 comments on commit 02e5369

Please sign in to comment.