[Bug c++/57335] internal compiler error: in cxx_eval_bit_field_ref, at cp/semantics.c:6977
paolo.carlini at oracle dot com
gcc-bugzilla@gcc.gnu.org
Wed Sep 3 16:07:00 GMT 2014
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=57335
--- Comment #4 from Paolo Carlini <paolo.carlini at oracle dot com> ---
The code in cxx_eval_bit_field_ref needs some work, doesn't handle CONSTRUCTORs
inside CONSTRUCTORs. This is a reduced testcase:
struct BitsOrderCheck
{
struct Data
{
const unsigned char set:1;
constexpr Data() : set{1} {}
};
constexpr bool IsLsbBottom() const
{
return 1 == data_.set;
}
const Data data_;
};
static_assert(BitsOrderCheck().IsLsbBottom(), "blah");
More information about the Gcc-bugs
mailing list