Skip to content
Permalink
Browse files

Cleanup earlier tokenization bug fix

  • Loading branch information...
sp1187 committed Sep 21, 2019
1 parent b25f269 commit 8189eaeb72a2a529e9a2a79b41207cdd2d70cec2
Showing with 2 additions and 3 deletions.
  1. +2 −3 Parser/Tokenizer.cpp
@@ -538,8 +538,7 @@ Token FileTokenizer::loadToken()
bool isValid = true;
bool foundPoint = false;
bool foundExp = false;
bool isHex = start+1 < currentLine.size() && currentLine[start] == '0' &&
(currentLine[start+1] == 'x' || currentLine[start+1] == 'X');
bool isHex = start+1 < currentLine.size() && currentLine[start] == '0' && towlower(currentLine[start+1]) == 'x';

while (end < currentLine.size() && (iswalnum(currentLine[end]) || currentLine[end] == '.'))
{
@@ -548,7 +547,7 @@ Token FileTokenizer::loadToken()
if (isHex || foundExp || foundPoint)
isValid = false;
foundPoint = true;
} else if (currentLine[end] == 'h' || currentLine[end] == 'H') {
} else if (towlower(currentLine[end]) == 'h') {
isHex = true;
} else if (towlower(currentLine[end]) == 'e' && !isHex)
{

0 comments on commit 8189eae

Please sign in to comment.
You can’t perform that action at this time.