Mail Archives: djgpp/1996/09/06/02:54:08
John M. Aldrich wrote:
> You should always define extern variables in _exactly_ the same way you
> define them in the 'home' module. Anything else could get you into trouble.
I believe you're guaranteed that
extern char my_global_array[];
will work in any case. Someone else (Eli? You're always good at catching my
mistakes) could probably verify this.
The external declaration
extern char *my_global_array;
however, definitely will _not_ work. Pointers and arrays are similar, but
they are not the same thing, particularly when defined globally.
--
Erik Max Francis, &tSftDotIotE http://www.alcyone.com/max/ max AT alcyone DOT com
San Jose, California ICBM 37 20 07 N 121 53 38 W R^4: the 4th R is respect
"Out from his breast/his soul went to seek/the doom of the just." -- _Beowulf_
- Raw text -