This is the mail archive of the gcc-bugs@gcc.gnu.org mailing list for the GCC project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

[Bug c++/32549] Wrong template instance resolution among multiple object files.



------- Comment #4 from bangerth at dealii dot org  2007-09-08 23:52 -------
The code is definitely invalid. The two typedefs declare two types with
external linkage. This is an ODR violation making the code invalid. The
standard doesn't require compilers to produce an error for a very good
reason: it is almost impossible to detect this without support from a linker
that understands all wrinkles and depths of the C++ language.


-- 

bangerth at dealii dot org changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
                 CC|                            |bangerth at dealii dot org
             Status|UNCONFIRMED                 |RESOLVED
         Resolution|                            |INVALID


http://gcc.gnu.org/bugzilla/show_bug.cgi?id=32549


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]