[cfe-commits] r64153 - in /cfe/trunk: include/clang/AST/ASTContext.h include/clang/AST/DeclTemplate.h include/clang/AST/Type.h include/clang/Parse/Action.h include/clang/Parse/Parser.h lib/AST/ASTContext.cpp lib/AST/DeclTemplate.cpp lib/AST/Type.cpp lib/AST/TypeSerialization.cpp lib/CodeGen/CodeGenTypes.cpp lib/Parse/MinimalAction.cpp lib/Parse/ParseDecl.cpp lib/Parse/ParseExpr.cpp lib/Parse/ParseTemplate.cpp lib/Parse/Parser.cpp lib/Sema/Sema.h lib/Sema/SemaTemplate.cpp test/SemaTemplate/class-template-id.cpp

Chris Lattner clattner at apple.com
Tue Feb 10 21:14:48 PST 2009


On Feb 10, 2009, at 5:06 PM, Douglas Gregor wrote:
>>>> I suppose it can't be helped.
>>>
>>> The only other option I can think of would be to pass it as a  
>>> boolean
>>> flag down the stack... that's almost worse :)
>>
>> Naive question: is this just a matter of parsing the expression  
>> starting at the right precedence level?
>
> Sadly, no; other operations at that same precedence level (<, <=,  
> >=) can still show up. For example,
>
> 	A< 5 < 0> *a;
>
> is well-formed.
>
> Plus, in C++0x, '>>' can also terminate a template-argument-list or  
> a default template argument. (And there's some fancy footwork to be  
> done to recover from "vector<vector<int>>" in C++98 mode).

*sigh* ok.  The monkeys in the standards committee win again.  Wait,  
did I say that out loud? ;-)

-Chris



More information about the cfe-commits mailing list