[llvm-bugs] [Bug 24988] New: gcc -Wattribute warnings for several libc++ headers

via llvm-bugs llvm-bugs at lists.llvm.org
Tue Sep 29 13:27:37 PDT 2015


https://llvm.org/bugs/show_bug.cgi?id=24988

            Bug ID: 24988
           Summary: gcc -Wattribute warnings for several libc++ headers
           Product: libc++
           Version: unspecified
          Hardware: All
                OS: All
            Status: NEW
          Severity: normal
          Priority: P
         Component: All Bugs
          Assignee: unassignedclangbugs at nondot.org
          Reporter: dimitry at andric.com
                CC: llvm-bugs at lists.llvm.org, mclow.lists at gmail.com
    Classification: Unclassified

Created attachment 14956
  --> https://llvm.org/bugs/attachment.cgi?id=14956&action=edit
libc++ -Wattributes warnings from gcc 4.9.2

When building libc++ with gcc 4.9.2, there are quite a number of -Wattributes
warnings.  A log of all of them is attached.

They are either "type attributes ignored after type is already defined", for
example with _LIBCPP_DECLARE_STRONG_ENUM:

In file included from include/__mutex_base:16:0,
                 from include/condition_variable:111,
                 from src/condition_variable.cpp:14:
include/system_error:345:1: warning: type attributes ignored after type is
already defined [-Wattributes]
 };
 ^

or "visibility attribute ignored because it conflicts with previous
declaration", like with:

In file included from include/memory:604:0,
                 from include/condition_variable:112,
                 from src/condition_variable.cpp:14:
include/utility:471:50: warning: type attributes ignored after type is already
defined [-Wattributes]
 template <class _Tp> class _LIBCPP_TYPE_VIS_ONLY reference_wrapper;
                                                  ^
In file included from src/condition_variable.cpp:14:0:
include/condition_variable:161:1: warning: 
std::__1::condition_variable_any::condition_variable_any() : visibility
attribute ignored because it [-Wattributes]
 condition_variable_any::condition_variable_any()
 ^
include/condition_variable:127:5: warning: conflicts with previous declaration
here [-Wattributes]
     condition_variable_any();
     ^
include/condition_variable:129:10: warning: conflicts with previous declaration
here [-Wattributes]
     void notify_one() _NOEXCEPT;
          ^
include/condition_variable:130:10: warning: conflicts with previous declaration
here [-Wattributes]
     void notify_all() _NOEXCEPT;
          ^

-- 
You are receiving this mail because:
You are on the CC list for the bug.
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.llvm.org/pipermail/llvm-bugs/attachments/20150929/85a96aae/attachment.html>


More information about the llvm-bugs mailing list