diff options
author | Richard Smith <richard-llvm@metafoo.co.uk> | 2013-02-19 23:47:15 +0000 |
---|---|---|
committer | Richard Smith <richard-llvm@metafoo.co.uk> | 2013-02-19 23:47:15 +0000 |
commit | 053214013990ad8ec096dafc64aa7c0ad2b05bc0 (patch) | |
tree | 780636c1e0577c4aa63aa31e832b8f8324079cb4 /include/clang/Basic | |
parent | 65f991ccbec43b4a860f70594c92528ee8fb7c6f (diff) |
PR15300: Support C++11 attributes on base-specifiers. We don't support any such
attributes yet, so just issue the appropriate diagnostics. Also generalize the
fixit for attributes-in-the-wrong-place code and reuse it here, if attributes
are placed after the access-specifier or 'virtual' in a base specifier.
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@175575 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'include/clang/Basic')
-rw-r--r-- | include/clang/Basic/DiagnosticSemaKinds.td | 7 |
1 files changed, 4 insertions, 3 deletions
diff --git a/include/clang/Basic/DiagnosticSemaKinds.td b/include/clang/Basic/DiagnosticSemaKinds.td index 44bcf632a6..2bacb2cff9 100644 --- a/include/clang/Basic/DiagnosticSemaKinds.td +++ b/include/clang/Basic/DiagnosticSemaKinds.td @@ -1801,9 +1801,8 @@ def warn_cxx11_gnu_attribute_on_type : Warning< def warn_unhandled_ms_attribute_ignored : Warning< "__declspec attribute %0 is not supported">, InGroup<IgnoredAttributes>; -def warn_attribute_invalid_on_stmt : Warning< - "attribute %0 cannot be specified on a statement">, - InGroup<IgnoredAttributes>; +def err_attribute_invalid_on_stmt : Error< + "%0 attribute cannot be applied to a statement">; def warn_declspec_attribute_ignored : Warning< "attribute %0 is ignored, place it after " "\"%select{class|struct|union|interface|enum}1\" to apply attribute to " @@ -1905,6 +1904,8 @@ def err_attribute_can_be_applied_only_to_value_decl : Error< "%0 attribute can only be applied to value declarations">; def warn_attribute_not_on_decl : Warning< "%0 attribute ignored when parsing type">, InGroup<IgnoredAttributes>; +def err_base_specifier_attribute : Error< + "%0 attribute cannot be applied to a base specifier">; // Availability attribute def warn_availability_unknown_platform : Warning< |