[cfe-dev] Warning flag for attribute warnings

Tanya Lattner lattner at apple.com
Tue Jul 10 10:32:20 PDT 2012


I've added a new warning for an OpenCL attribute and it needs to go under a flag. I noticed that in the Misc/warning-flags.c test there are a bunch of attribute warnings that do not have flags.

I think that the group "IgnoredAttribute" would apply to the warning I added and the following below as most are because the attribute is incorrectly applied and therefore ignored.

Please let me know what you think and I'll go clean these up. 

Here is the warning I added:
warn_duplicate_attribute

Here is the list:
CHECK-NEXT:   warn_attribute_ibaction
CHECK-NEXT:   warn_attribute_iboutlet
CHECK-NEXT:   warn_attribute_ignored
CHECK-NEXT:   warn_attribute_ignored_for_field_of_type
CHECK-NEXT:   warn_attribute_malloc_pointer_only
CHECK-NEXT:   warn_attribute_nonnull_no_pointers
CHECK-NEXT:   warn_attribute_precede_definition
CHECK-NEXT:   warn_attribute_sentinel_named_arguments
CHECK-NEXT:   warn_attribute_sentinel_not_variadic
CHECK-NEXT:   warn_attribute_type_not_supported
CHECK-NEXT:   warn_attribute_unknown_visibility
CHECK-NEXT:   warn_attribute_void_function_method
CHECK-NEXT:   warn_attribute_weak_import_invalid_on_definition
CHECK-NEXT:   warn_attribute_weak_on_field
CHECK-NEXT:   warn_attribute_weak_on_local
CHECK-NEXT:   warn_attribute_wrong_decl_type
CHECK-NEXT:   warn_function_attribute_wrong_type
CHECK-NEXT:   warn_gnu_inline_attribute_requires_inline
CHECK-NEXT:   warn_ns_attribute_wrong_parameter_type
CHECK-NEXT:   warn_ns_attribute_wrong_return_type
CHECK-NEXT:   warn_objc_object_attribute_wrong_type
CHECK-NEXT:   warn_pointer_attribute_wrong_type
CHECK-NEXT:   warn_transparent_union_attribute_field_size_align
CHECK-NEXT:   warn_transparent_union_attribute_floating
CHECK-NEXT:   warn_transparent_union_attribute_not_definition
CHECK-NEXT:   warn_transparent_union_attribute_zero_fields

-Tanya
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.llvm.org/pipermail/cfe-dev/attachments/20120710/5039aef0/attachment.html>


More information about the cfe-dev mailing list