public inbox for gcc-bugs@sourceware.org
help / color / mirror / Atom feed
* [Bug libstdc++/112467] New: [14 Regression] libstdc++ fails to build on clang: bits/stl_bvector.h:189:23: error: '__assume__' attribute cannot be applied to a statement
@ 2023-11-09 19:38 slyfox at gcc dot gnu.org
  2023-11-09 19:49 ` [Bug libstdc++/112467] " pinskia at gcc dot gnu.org
                   ` (10 more replies)
  0 siblings, 11 replies; 12+ messages in thread
From: slyfox at gcc dot gnu.org @ 2023-11-09 19:38 UTC (permalink / raw)
  To: gcc-bugs

https://gcc.gnu.org/bugzilla/show_bug.cgi?id=112467

            Bug ID: 112467
           Summary: [14 Regression] libstdc++ fails to build on clang:
                    bits/stl_bvector.h:189:23: error: '__assume__'
                    attribute cannot be applied to a statement
           Product: gcc
           Version: 14.0
            Status: UNCONFIRMED
          Severity: normal
          Priority: P3
         Component: libstdc++
          Assignee: unassigned at gcc dot gnu.org
          Reporter: slyfox at gcc dot gnu.org
  Target Milestone: ---

Build failure is probably introduced by r14-5260-ge39b3e02c27bd7 and fails on
clang-16 as:

    // $ cat a.cc
    #include <vector>

$ clang++ -c a.cc
In file included from a.cc:1:
In file included from /<<NIX>>/gcc-14.0.0/include/c++/14.0.0/vector:67:
/<<NIX>>/gcc-14.0.0/include/c++/14.0.0/bits/stl_bvector.h:189:23: error:
'__assume__' attribute cannot be applied to a statement
      __attribute__ ((__assume__ (__ofst < unsigned(_S_word_bit))));
                      ^                                            ~
1 error generated.

I think it happens because `clang` implements different `assume` attribute
compared to `gcc`: https://clang.llvm.org/docs/AttributeReference.html#assume

^ permalink raw reply	[flat|nested] 12+ messages in thread

end of thread, other threads:[~2024-02-09  8:46 UTC | newest]

Thread overview: 12+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2023-11-09 19:38 [Bug libstdc++/112467] New: [14 Regression] libstdc++ fails to build on clang: bits/stl_bvector.h:189:23: error: '__assume__' attribute cannot be applied to a statement slyfox at gcc dot gnu.org
2023-11-09 19:49 ` [Bug libstdc++/112467] " pinskia at gcc dot gnu.org
2023-11-09 19:49 ` slyfox at gcc dot gnu.org
2023-11-09 19:50 ` pinskia at gcc dot gnu.org
2023-11-09 21:15 ` redi at gcc dot gnu.org
2023-11-09 21:15 ` redi at gcc dot gnu.org
2023-11-10  8:26 ` rguenth at gcc dot gnu.org
2023-11-10 20:58 ` sjames at gcc dot gnu.org
2023-11-10 21:05 ` redi at gcc dot gnu.org
2023-11-11  0:58 ` cvs-commit at gcc dot gnu.org
2023-11-11  1:01 ` redi at gcc dot gnu.org
2024-02-09  8:46 ` cvs-commit at gcc dot gnu.org

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).