CLI2: Expand DOM references in single-token values
This commit is contained in:
@@ -1323,6 +1323,20 @@ bool Lexer::isAllDigits (const std::string& text)
|
||||
return text.find_first_not_of ("0123456789") == std::string::npos;
|
||||
}
|
||||
|
||||
////////////////////////////////////////////////////////////////////////////////
|
||||
bool Lexer::isDOM (const std::string& text)
|
||||
{
|
||||
Lexer lex (text);
|
||||
int count = 0;
|
||||
std::string token;
|
||||
Lexer::Type type;
|
||||
while (lex.token (token, type))
|
||||
++count;
|
||||
|
||||
return count == 1 &&
|
||||
type == Lexer::Type::dom;
|
||||
}
|
||||
|
||||
////////////////////////////////////////////////////////////////////////////////
|
||||
// Full implementation of a quoted word. Includes:
|
||||
// '\''
|
||||
|
||||
Reference in New Issue
Block a user