[Bug libstdc++/103295] constexpr std::string does not work for clang

2022-11-14 Thread cvs-commit at gcc dot gnu.org via Gcc-bugs
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=103295 --- Comment #22 from CVS Commits --- The releases/gcc-12 branch has been updated by Jonathan Wakely : https://gcc.gnu.org/g:a088d93c210f9b662d706e2fcf63a59d05fe27c1 commit r12-8908-ga088d93c210f9b662d706e2fcf63a59d05fe27c1 Author: Nathaniel

[Bug libstdc++/103295] constexpr std::string does not work for clang

2022-11-11 Thread cvs-commit at gcc dot gnu.org via Gcc-bugs
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=103295 --- Comment #21 from CVS Commits --- The master branch has been updated by Jonathan Wakely : https://gcc.gnu.org/g:52672be7d328df50f9a05ce3ab44ebcae50fee1b commit r13-3910-g52672be7d328df50f9a05ce3ab44ebcae50fee1b Author: Nathaniel Shead

[Bug libstdc++/103295] constexpr std::string does not work for clang

2021-11-19 Thread redi at gcc dot gnu.org via Gcc-bugs
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=103295 Jonathan Wakely changed: What|Removed |Added Resolution|--- |FIXED Target Milestone|---

[Bug libstdc++/103295] constexpr std::string does not work for clang

2021-11-19 Thread cvs-commit at gcc dot gnu.org via Gcc-bugs
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=103295 --- Comment #19 from CVS Commits --- The master branch has been updated by Jonathan Wakely : https://gcc.gnu.org/g:1f8d01eb1476a997eb1fc686b60fccdf97747faa commit r12-5421-g1f8d01eb1476a997eb1fc686b60fccdf97747faa Author: Jonathan Wakely

[Bug libstdc++/103295] constexpr std::string does not work for clang

2021-11-19 Thread redi at gcc dot gnu.org via Gcc-bugs
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=103295 --- Comment #18 from Jonathan Wakely --- There's still one more fix needed for _M_construct

[Bug libstdc++/103295] constexpr std::string does not work for clang

2021-11-19 Thread cvs-commit at gcc dot gnu.org via Gcc-bugs
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=103295 --- Comment #17 from CVS Commits --- The master branch has been updated by Jonathan Wakely : https://gcc.gnu.org/g:2d76292bd6719d687bc77051da265df8ed7f5a61 commit r12-5413-g2d76292bd6719d687bc77051da265df8ed7f5a61 Author: Jonathan Wakely

[Bug libstdc++/103295] constexpr std::string does not work for clang

2021-11-17 Thread rguenth at gcc dot gnu.org via Gcc-bugs
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=103295 Richard Biener changed: What|Removed |Added Target Milestone|12.0|---

[Bug libstdc++/103295] constexpr std::string does not work for clang

2021-11-17 Thread unlvsur at live dot com via Gcc-bugs
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=103295 --- Comment #16 from cqwrteur --- (In reply to Jonathan Wakely from comment #15) > Reopened :-( > > I have a patch to make clang happy, but I think what we really want is a > language change. hi jwakely. i am trying to add a new patch to

[Bug libstdc++/103295] constexpr std::string does not work for clang

2021-11-17 Thread redi at gcc dot gnu.org via Gcc-bugs
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=103295 Jonathan Wakely changed: What|Removed |Added Resolution|FIXED |--- Status|RESOLVED

[Bug libstdc++/103295] constexpr std::string does not work for clang

2021-11-17 Thread redi at gcc dot gnu.org via Gcc-bugs
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=103295 Jonathan Wakely changed: What|Removed |Added Status|ASSIGNED|RESOLVED Resolution|---

[Bug libstdc++/103295] constexpr std::string does not work for clang

2021-11-17 Thread cvs-commit at gcc dot gnu.org via Gcc-bugs
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=103295 --- Comment #13 from CVS Commits --- The master branch has been updated by Jonathan Wakely : https://gcc.gnu.org/g:6afa1083c6ee7b31629fb0c16299b952cb17868c commit r12-5343-g6afa1083c6ee7b31629fb0c16299b952cb17868c Author: Jonathan Wakely

[Bug libstdc++/103295] constexpr std::string does not work for clang

2021-11-17 Thread redi at gcc dot gnu.org via Gcc-bugs
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=103295 --- Comment #12 from Jonathan Wakely --- But even with those problems fixed, Clang fails for anything that doesn't fit in the SSO buffer, as shown by this: #include constexpr char test() { char* p = std::allocator().allocate(2); p[0] =

[Bug libstdc++/103295] constexpr std::string does not work for clang

2021-11-17 Thread redi at gcc dot gnu.org via Gcc-bugs
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=103295 --- Comment #11 from Jonathan Wakely --- (In reply to Jonathan Wakely from comment #7) > It just doesn't allow assignment through the pointer. I think that's correct according to [class.union.general] p6: "When the left operand of an

[Bug libstdc++/103295] constexpr std::string does not work for clang

2021-11-17 Thread redi at gcc dot gnu.org via Gcc-bugs
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=103295 --- Comment #10 from Jonathan Wakely --- (Do you really need to quote the whole of comment 9 to reply to comment 8?) You can't, it's not freely available.

[Bug libstdc++/103295] constexpr std::string does not work for clang

2021-11-17 Thread unlvsur at live dot com via Gcc-bugs
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=103295 --- Comment #9 from cqwrteur --- (In reply to Jonathan Wakely from comment #8) > Which means this is enough to make Clang happy for the comment 0 example: > > --- a/libstdc++-v3/include/bits/basic_string.tcc > +++

[Bug libstdc++/103295] constexpr std::string does not work for clang

2021-11-17 Thread redi at gcc dot gnu.org via Gcc-bugs
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=103295 --- Comment #8 from Jonathan Wakely --- Which means this is enough to make Clang happy for the comment 0 example: --- a/libstdc++-v3/include/bits/basic_string.tcc +++ b/libstdc++-v3/include/bits/basic_string.tcc @@ -167,6 +167,11 @@

[Bug libstdc++/103295] constexpr std::string does not work for clang

2021-11-17 Thread redi at gcc dot gnu.org via Gcc-bugs
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=103295 --- Comment #7 from Jonathan Wakely --- The code can be reduced to this, which GCC, EDG and MSVC all accept, but Clang doesn't: struct S { union { char buf[8]; char* ptr; }; unsigned len; constexpr S(const char* s, unsigned n)

[Bug libstdc++/103295] constexpr std::string does not work for clang

2021-11-16 Thread redi at gcc dot gnu.org via Gcc-bugs
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=103295 Jonathan Wakely changed: What|Removed |Added Target Milestone|--- |12.0

[Bug libstdc++/103295] constexpr std::string does not work for clang

2021-11-16 Thread redi at gcc dot gnu.org via Gcc-bugs
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=103295 Jonathan Wakely changed: What|Removed |Added Status|UNCONFIRMED |ASSIGNED Last reconfirmed|

[Bug libstdc++/103295] constexpr std::string does not work for clang

2021-11-16 Thread unlvsur at live dot com via Gcc-bugs
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=103295 --- Comment #5 from cqwrteur --- (In reply to Andrew Pinski from comment #3) > This could be an unimplemented feature in clang with respect to C++23 by the > way. The problem is that it has a silent undefined behavior in the code, the string

[Bug libstdc++/103295] constexpr std::string does not work for clang

2021-11-16 Thread unlvsur at live dot com via Gcc-bugs
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=103295 --- Comment #4 from cqwrteur --- (In reply to Andrew Pinski from comment #3) > This could be an unimplemented feature in clang with respect to C++23 by the > way. Same code works with clang --target=x86_64-windows-msvc.

[Bug libstdc++/103295] constexpr std::string does not work for clang

2021-11-16 Thread pinskia at gcc dot gnu.org via Gcc-bugs
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=103295 --- Comment #3 from Andrew Pinski --- This could be an unimplemented feature in clang with respect to C++23 by the way.

[Bug libstdc++/103295] constexpr std::string does not work for clang

2021-11-16 Thread unlvsur at live dot com via Gcc-bugs
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=103295 --- Comment #2 from cqwrteur --- *** Bug 103294 has been marked as a duplicate of this bug. ***

[Bug libstdc++/103295] constexpr std::string does not work for clang

2021-11-16 Thread unlvsur at live dot com via Gcc-bugs
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=103295 cqwrteur changed: What|Removed |Added CC||unlvsur at live dot com --- Comment #1 from