mirror of
https://gitlab.com/OpenMW/openmw.git
synced 2025-01-26 09:35:28 +00:00
interpret instruction keywords as names within expressions
This commit is contained in:
parent
c0a6acfe6c
commit
93d4743012
@ -344,6 +344,17 @@ namespace Compiler
|
||||
|
||||
bool ExprParser::parseKeyword (int keyword, const TokenLoc& loc, Scanner& scanner)
|
||||
{
|
||||
if (const Extensions *extensions = getContext().getExtensions())
|
||||
{
|
||||
std::string argumentType; // ignored
|
||||
bool hasExplicit = false; // ignored
|
||||
if (extensions->isInstruction (keyword, argumentType, hasExplicit))
|
||||
{
|
||||
// pretend this is not a keyword
|
||||
return parseName (loc.mLiteral, loc, scanner);
|
||||
}
|
||||
}
|
||||
|
||||
mFirst = false;
|
||||
|
||||
if (!mExplicit.empty())
|
||||
|
Loading…
x
Reference in New Issue
Block a user