The second place where you used Person for declaration looks as follows under the effect of typedef........
Person { char name[11]; int age ; }; looks like--------------> struct Person {} { char name[11]; int age ; }; Coz, Person is of type 'struct Person' which is empty structure..........Try above syntax, YOU WILL DEFINETLY GET THE SAME ERROR AND CONCLUDE YOURSELF THE WORKING OF "TYPEDEF" |
All times are GMT -5. The time now is 12:59 AM. |