V
Vijay Kumar R Zanvar
I have the following question:
1. According to 6.2.7P1 of Std, are the
following structures compatible?
(Assume you compile with proper options)
/* compatible.c */
#include <stdio.h>
struct A
{
int a;
char b;
};
int
main ( void )
{
struct A a = { 5, 'a' };
extern struct A b;
b = a;
printf ( "%d %c\n", b.a, b.b );
return 0;
}
/* compatible2.c */
struct A
{
int a;
char b;
};
Thanks
1. According to 6.2.7P1 of Std, are the
following structures compatible?
(Assume you compile with proper options)
/* compatible.c */
#include <stdio.h>
struct A
{
int a;
char b;
};
int
main ( void )
{
struct A a = { 5, 'a' };
extern struct A b;
b = a;
printf ( "%d %c\n", b.a, b.b );
return 0;
}
/* compatible2.c */
struct A
{
int a;
char b;
};
Thanks