diff --git a/src/Context.cpp b/src/Context.cpp index 80041dc43..4560b2cbb 100644 --- a/src/Context.cpp +++ b/src/Context.cpp @@ -172,7 +172,7 @@ int Context::initialize (int argc, const char** argv) for (col = columns.begin (); col != columns.end (); ++col) parser.entity ("attribute", col->first); - // Entities: Pseudo-attributes. + // Entities: Pseudo-attributes. Hard-coded. parser.entity ("pseudo", "limit"); // Entities: Modifiers. @@ -191,7 +191,7 @@ int Context::initialize (int argc, const char** argv) parser.findCommand (); // parser.findUUIDList (); // Before findIdSequence parser.findIdSequence (); // - parser.injectDefaults (); // rc.default.command + parser.injectDefaults (); // rc.default.command // Static initialization to decouple code. staticInitialization (); diff --git a/src/Lexer.cpp b/src/Lexer.cpp index 10c23a07c..b696bb6a8 100644 --- a/src/Lexer.cpp +++ b/src/Lexer.cpp @@ -225,6 +225,15 @@ bool Lexer::token (std::string& token, Type& type) } else { + // typeIdentifier is a catch-all type. Anything word-like becomes an + // identifier. At this point in the processing, an identifier is found, + // and can be matched against a list of potential upgrades. + if (token == "_hastag_" || + token == "_notag_" || + token == "_neg_" || + token == "_pos_") + type = typeOperator; + return true; } break;