I have the following code:
#include <stdio.h>
int main(void)
{
char c1 = 'A';
int size1;
int size2;
size1 = sizeof(c1);
size2 = sizeof('A');
printf("%d %d\n", size1, size2);
return 0;
}
The output of the above code is 1 4. My question why 'A' in sizeof('A') is promoted to a integer, while c1 in sizeof(c1) is not promoted to a interger?