This is the mail archive of the
gcc-bugs@gcc.gnu.org
mailing list for the GCC project.
[Bug c++/25915] use ODR rules to make C++ objects not be TREE_PUBLIC
- From: "pinskia at gcc dot gnu dot org" <gcc-bugzilla at gcc dot gnu dot org>
- To: gcc-bugs at gcc dot gnu dot org
- Date: 21 Jun 2006 18:44:35 -0000
- Subject: [Bug c++/25915] use ODR rules to make C++ objects not be TREE_PUBLIC
- References: <bug-25915-6809@http.gcc.gnu.org/bugzilla/>
- Reply-to: gcc-bugzilla at gcc dot gnu dot org
------- Comment #8 from pinskia at gcc dot gnu dot org 2006-06-21 18:44 -------
(In reply to comment #2)
> then my_other_class can also be made non-TREE_PUBLIC. If 'x' was in an
> anonymous namespace the logic would be the same.
Actually it cannot because I define in a different TU my_other_class and now I
get an ODR violation. Likewise for myclass. Yes this is all undefined but I
rather have it be diagnose than having it be undefined behavior.
--
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=25915