cppBad.vert
-ERROR: 0:2: 'preprocessor evaluation' : bad expression
-ERROR: 0:2: '#if' : unexpected tokens following directive
-ERROR: 0:5: 'string' : End of line in string
-ERROR: 0:5: '""' : string literals not supported
-ERROR: 0:5: '' : syntax error, unexpected INT, expecting COMMA or SEMICOLON
+WARNING: 0:1: '#define' : missing space after macro name
+ERROR: 0:3: 'preprocessor evaluation' : bad expression
+ERROR: 0:3: '#if' : unexpected tokens following directive
+ERROR: 0:6: 'string' : End of line in string
+ERROR: 0:6: '""' : string literals not supported
+ERROR: 0:6: '' : syntax error, unexpected INT, expecting COMMA or SEMICOLON
ERROR: 5 compilation errors. No code generated.
--- /dev/null
+cppBad3.vert
+ERROR: 0:3: 'macro expansion' : End of input in macro y
+ERROR: 1 compilation errors. No code generated.
+
+
+Shader version: 100
+ERROR: node is still EOpNull!
+0:? Linker Objects
+
+
+Linked vertex stage:
+
+ERROR: Linking vertex stage: Missing entry point: Each stage requires one entry point
+
+Shader version: 100
+ERROR: node is still EOpNull!
+0:? Linker Objects
+
}
token = scanToken(ppToken);
+ } else if (token != '\n' && token != EndOfInput && !ppToken->space) {
+ parseContext.ppWarn(ppToken->loc, "missing space after macro name", "#define", "");
+
+ return token;
}
// record the definition of the macro
// Handle token-pasting logic
token = tokenPaste(token, ppToken);
- if (token == EndOfInput) {
+ if (token == EndOfInput || token == tMarkerInput::marker) {
missingEndifCheck();
return EndOfInput;
}