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++/15531] dynamic_cast fails (at runtime) when dependant on friendship of invoker


------- Additional Comments From gdr at integrable-solutions dot net  2004-05-19 01:15 -------
Subject: Re:  dynamic_cast fails (at runtime) when dependant on friendship of invoker

"gccbugs at contacts dot eelis dot net" <gcc-bugzilla@gcc.gnu.org> writes:

| I see, thanks for clearing that up.
| In this case, would it not be desirable to have gcc emit an error/warning
| indicating that the cast will always fail since Base is not a public
| base class of Derived?

yes, it could -- not in all cases -- but this is certainly a case when
the answer is known at translation time.  The PR could be open as
diagnostic enhancement and the subject changed to reflect the outcome
ot this discussion.

-- Gaby


-- 


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


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