mirror of
https://github.com/apple/swift.git
synced 2026-10-18 17:49:23 +02:00
The getter body previously read the member as a prvalue, which tripped Clang's C++11 constant evaluator assertion and crashed swift-frontend when IR-generating bit-field accessors under -cxx-interoperability-mode. rdar://158308810
11 lines
234 B
C
11 lines
234 B
C
#ifndef TEST_INTEROP_CXX_CLASS_INPUTS_BIT_FIELDS_H
|
|
#define TEST_INTEROP_CXX_CLASS_INPUTS_BIT_FIELDS_H
|
|
|
|
struct BitFields {
|
|
unsigned a : 3;
|
|
unsigned b : 5;
|
|
unsigned c : 24;
|
|
};
|
|
|
|
#endif // TEST_INTEROP_CXX_CLASS_INPUTS_BIT_FIELDS_H
|