Menu

#79 #pragma interface not working

open
nobody
None
5
2002-12-02
2002-12-02
Dale King
No

The #pragma interface and #pragma implementation
declarations which is a GNU extension to C++ that allows
you to specify declarations and definitions in the same
file, does not seem to work even though it is a feature of
GCC 2.95.3 which it is supposedly based off of. See
http://gcc.gnu.org/onlinedocs/gcc-
2.95.3/gcc_5.html#SEC109

Using the #pragma interface in a header file that has a
class declaration and the member definitions results in
an error from the linker because the definitions is
multiply defined. I get no such error from the normal
GCC tools (with version 3.2 that is, but the feature has
been present long before 2.95.3).

Discussion


Log in to post a comment.