aboutsummaryrefslogtreecommitdiff
path: root/clang/test/Parser/cxx-attributes.cpp
AgeCommit message (Collapse)AuthorFilesLines
2015-01-03Parse: __attribute__((keyword)) shouldn't errorDavid Majnemer1-1/+1
Weird constructs like __attribute__((inline)) or __attibute__((typename)) should result in warnings, not errors. llvm-svn: 225118
2014-12-28Parse: Don't crash when 'typename' shows up in an attributeDavid Majnemer1-0/+2
isDeclarationSpecifier performs error recovers which jostles the token stream. Specifically, TryAnnotateTypeOrScopeToken will end up consuming a typename token which will confuse the attribute parsing machinery as we no-longer have something identifier-like. llvm-svn: 224903
2013-10-31Factor out custom parsing for iboutletcollection and vec_type_hint attributesRichard Smith1-0/+3
into a separate "parse an attribute that takes a type argument" codepath. This results in both codepaths being a lot cleaner and simpler, and fixes some bugs where the type argument handling bled into the expression argument handling and caused us to both accept invalid and reject valid attribute arguments. llvm-svn: 193731
2013-10-24PR17666: Instead of allowing an initial identifier argument in any attributeRichard Smith1-0/+6
which we don't think can't have one, only allow it in the tiny number of attributes which opts into this weird parse rule. I've manually checked that the handlers for all these attributes can in fact cope with an identifier as the argument. This is still somewhat terrible; we should move more fully towards picking the parsing rules based on the attribute, and make the Parse -> Sema interface more type-safe. llvm-svn: 193295
2013-08-01Parse: Don't consider attributes of broken member declaratorsDavid Majnemer1-1/+4
ParseCXXClassMemberDeclaration was trying to use the result of ActOnCXXMemberDeclarator to attach it to some late parsed attributes. However when failures arise, we have no decl to attach to which eventually leads us to a NULL pointer dereference. While we are here, clean up the code a bit. Fixes PR16765 llvm-svn: 187557
2012-10-19Prior to adding the new "expected-no-diagnostics" directive to ↵Andy Gibbs1-0/+1
VerifyDiagnosticConsumer, make the necessary adjustment to 580 test-cases which will henceforth require this new directive. llvm-svn: 166280
2010-08-05Convert this file to not have Windows line endings -- likely committed fromChandler Carruth1-9/+9
Windows without svn:eol-style=native. llvm-svn: 110308
2009-12-15Update tests to use %clang_cc1 instead of 'clang-cc' or 'clang -cc1'.Daniel Dunbar1-1/+1
- This is designed to make it obvious that %clang_cc1 is a "test variable" which is substituted. It is '%clang_cc1' instead of '%clang -cc1' because it can be useful to redefine what gets run as 'clang -cc1' (for example, to set a default target). llvm-svn: 91446
2009-11-25Fix attribute between function decl ')' and '{' or '=0'John Thompson1-0/+9
llvm-svn: 89894