https://gcc.gnu.org/bugzilla/show_bug.cgi?id=103295
Bug ID: 103295
Summary: constexpr std::string does not work for clang
Product: gcc
Version: 12.0
Status: UNCONFIRMED
Severity: normal
Priority: P3
Component: libstdc++
Assignee: unassigned at gcc dot gnu.org
Reporter: unlvsur at live dot com
Target Milestone: ---
#include<string>
#include<cassert>
constexpr bool foo()
{
std::string str2{"abcwe"};
return str2.size()==5;
}
static_assert(foo());
int main()
{
assert(foo());
}
