

#pragma pack(push, 8)
struct A
{
	char c, d;
};
#pragma pack(pop)


struct B
{
	_Alignas(8) char c;
	_Alignas(8) char d;
};

///////

#pragma pack(push, 1)
struct C
{
	float c, d;
};
#pragma pack(pop)

/* crash, because 
    
    error: ‘_Alignas’ specifiers cannot reduce alignment of ‘c’
    
struct D
{
	_Alignas(1) float c;
	_Alignas(1) float d;
};
*/


#include <stdio.h>

int main(int argc, char** argv)
{
	struct A a;
	struct B b;
	struct C c;
//	struct D d;
	printf("size of A = %llu\n", sizeof(a));
	printf("size of B = %llu\n", sizeof(b));
	printf("size of C = %llu\n", sizeof(c));
//	printf("size of D = %llu\n", sizeof(d));
	
	return 0;
}