> Therefore "main" is an int.and
>        printf("Main: %d", main);
> Will print the address of main.

Well, main() is a function returning an int, which is not 
the same thing as an int. The function pointer (the memory 
address where the main() function code starts) is an integer 
type of some sort (probably a 32-bit unsigned int, but this 
will depend on the system), and presumably it's compatible 
with the "%d" format so no compile-time or run-time warnings 
are issued. But many compilers don't type-checking printf() 
arguments against the format string anyway.

David

Reply via email to