Re: extern question

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Hi Aseem,

> interestingly (or at least i think so :-) ), the code snippet that
> Trevis has given compiles and links using gcc BUT fails to link under
> g++ (2 times defined problem).

C++ has different rules than C about what constitutes a declaration versus a
definition.

(At least C89.  I'm not familiar with C99, which may have slightly different
rules.)

Sincerely,
--Eljay


[Index of Archives]     [Linux C Programming]     [Linux Kernel]     [eCos]     [Fedora Development]     [Fedora Announce]     [Autoconf]     [The DWARVES Debugging Tools]     [Yosemite Campsites]     [Yosemite News]     [Linux GCC]

  Powered by Linux