1335552e3fff9f41067cccfd72557f801d398949aEric Christopher// RUN: %clang_cc1 -emit-llvm %s -o /dev/null 2335552e3fff9f41067cccfd72557f801d398949aEric Christopherextern "C" { 3335552e3fff9f41067cccfd72557f801d398949aEric Christopher 4335552e3fff9f41067cccfd72557f801d398949aEric Christopher#pragma pack(push, 2) 5335552e3fff9f41067cccfd72557f801d398949aEric Christopher typedef struct ABC* abc; 6335552e3fff9f41067cccfd72557f801d398949aEric Christopher 7335552e3fff9f41067cccfd72557f801d398949aEric Christopher struct ABCS { 8335552e3fff9f41067cccfd72557f801d398949aEric Christopher float red; 9335552e3fff9f41067cccfd72557f801d398949aEric Christopher float green; 10335552e3fff9f41067cccfd72557f801d398949aEric Christopher float blue; 11335552e3fff9f41067cccfd72557f801d398949aEric Christopher float alpha; 12335552e3fff9f41067cccfd72557f801d398949aEric Christopher }; 13335552e3fff9f41067cccfd72557f801d398949aEric Christopher 14335552e3fff9f41067cccfd72557f801d398949aEric Christopher typedef void (*XYZ)(); 15335552e3fff9f41067cccfd72557f801d398949aEric Christopher#pragma pack(pop) 16335552e3fff9f41067cccfd72557f801d398949aEric Christopher} 17335552e3fff9f41067cccfd72557f801d398949aEric Christopher 18335552e3fff9f41067cccfd72557f801d398949aEric Christopher 19335552e3fff9f41067cccfd72557f801d398949aEric Christopherunion ABCU { 20335552e3fff9f41067cccfd72557f801d398949aEric Christopher ABCS color; 21335552e3fff9f41067cccfd72557f801d398949aEric Christopher XYZ bg; 22335552e3fff9f41067cccfd72557f801d398949aEric Christopher}; 23335552e3fff9f41067cccfd72557f801d398949aEric Christopher 24335552e3fff9f41067cccfd72557f801d398949aEric Christopherstruct AData { 25335552e3fff9f41067cccfd72557f801d398949aEric Christopher ABCU data; 26335552e3fff9f41067cccfd72557f801d398949aEric Christopher}; 27335552e3fff9f41067cccfd72557f801d398949aEric Christopher 28335552e3fff9f41067cccfd72557f801d398949aEric Christopherclass L { 29335552e3fff9f41067cccfd72557f801d398949aEric Christopher public: 30335552e3fff9f41067cccfd72557f801d398949aEric Christopher L() {} 31335552e3fff9f41067cccfd72557f801d398949aEric Christopher L(const L& other); 32335552e3fff9f41067cccfd72557f801d398949aEric Christopher 33335552e3fff9f41067cccfd72557f801d398949aEric Christopher private: 34335552e3fff9f41067cccfd72557f801d398949aEric Christopher AData fdata; 35335552e3fff9f41067cccfd72557f801d398949aEric Christopher}; 36335552e3fff9f41067cccfd72557f801d398949aEric Christopher 37335552e3fff9f41067cccfd72557f801d398949aEric Christopher 38335552e3fff9f41067cccfd72557f801d398949aEric ChristopherL::L(const L& other) 39335552e3fff9f41067cccfd72557f801d398949aEric Christopher{ 40335552e3fff9f41067cccfd72557f801d398949aEric Christopher fdata = other.fdata; 41335552e3fff9f41067cccfd72557f801d398949aEric Christopher} 42