PP: Recognize the '::' token, and translate appropriately to GLSL/HLSL token.
This commit is contained in:
@@ -120,6 +120,8 @@ const struct {
|
||||
{ PpAtomDecrement, "--" },
|
||||
{ PpAtomIncrement, "++" },
|
||||
|
||||
{ PpAtomColonColon, "::" },
|
||||
|
||||
{ PpAtomDefine, "define" },
|
||||
{ PpAtomUndef, "undef" },
|
||||
{ PpAtomIf, "if" },
|
||||
|
||||
@@ -691,6 +691,12 @@ int TPpContext::tStringInput::scan(TPpToken* ppToken)
|
||||
pp->parseContext.ppError(ppToken->loc, "End of line in string", "string", "");
|
||||
}
|
||||
return PpAtomConstString;
|
||||
case ':':
|
||||
ch = getch();
|
||||
if (ch == ':')
|
||||
return PpAtomColonColon;
|
||||
ungetch();
|
||||
return ':';
|
||||
}
|
||||
|
||||
ch = getch();
|
||||
|
||||
@@ -117,6 +117,8 @@ enum EFixedAtoms {
|
||||
PpAtomDecrement,
|
||||
PpAtomIncrement,
|
||||
|
||||
PpAtomColonColon,
|
||||
|
||||
PpAtomPaste,
|
||||
|
||||
// Constants
|
||||
|
||||
Reference in New Issue
Block a user