Currently the initial value of Tok is dependent an the stack contents

and could cause the Parser to crash on the first ConsumeToken().

Patcy by Bas van den Berg!

llvm-svn: 166891
This commit is contained in:
Chris Lattner 2012-10-27 19:49:20 +00:00
parent 57143f7e78
commit d5705d1b1c
1 changed files with 1 additions and 0 deletions

View File

@ -53,6 +53,7 @@ Parser::Parser(Preprocessor &pp, Sema &actions, bool SkipFunctionBodies)
GreaterThanIsOperator(true), ColonIsSacred(false),
InMessageExpression(false), TemplateParameterDepth(0),
ParsingInObjCContainer(false), SkipFunctionBodies(SkipFunctionBodies) {
Tok.startToken();
Tok.setKind(tok::eof);
Actions.CurScope = 0;
NumCachedScopes = 0;