Parse: Get rid of tok::cxx_defaultarg_end, use EOF instead
I added setEofData/getEofData to solve this sort of problem back in
r224505. Use the Param's decl to tell us if this is *our* EOF token.
llvm-svn: 225619
diff --git a/clang/lib/Parse/ParseDecl.cpp b/clang/lib/Parse/ParseDecl.cpp
index 7ff39aa..66366d9 100644
--- a/clang/lib/Parse/ParseDecl.cpp
+++ b/clang/lib/Parse/ParseDecl.cpp
@@ -5631,8 +5631,9 @@
// stop when we parse it later on.
Token DefArgEnd;
DefArgEnd.startToken();
- DefArgEnd.setKind(tok::cxx_defaultarg_end);
+ DefArgEnd.setKind(tok::eof);
DefArgEnd.setLocation(Tok.getLocation());
+ DefArgEnd.setEofData(Param);
DefArgToks->push_back(DefArgEnd);
Actions.ActOnParamUnparsedDefaultArgument(Param, EqualLoc,
(*DefArgToks)[1].getLocation());