I have a data type, say X, and I want to know its size without declaring a variable or pointer of that type and of course without using sizeof oper
X
sizeof
Try this:
int a; printf("%u\n", (int)(&a+1)-(int)(&a));