This is the mail archive of the gcc@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]

re: An odd behavior of dynamic_cast


Hi Dan,

> I think the right place for this question might have
> been gcc-help (http://gcc.gnu.org/ml/gcc-help/).

Thanks to Ben, I've already posted the same question to
gcc-help.

> > [ Why doesn't dynamic_cast work when I dlopen a
> shared library? ]

I've checked out http://gcc.gnu.org/faq.html#dso.
But in fact, I'm writing python extention module,
so I can't call dlopen() with RTLD_GLOBAL flag.

My actual question is:
- Why dynamic_cast across shared libraries
  works for VirtualTag in test1?
  (though I use dlopen() in test1.)
- Is it correct to use this workaround
  (i.e. making a class polymorphic)
  when I can't use RTLD_GLOBAL flag?

Thanks.


--- Dan Kegel <dank@kegel.com> wrote:
> shin1_morita@yahoo.co.jp wrote:
> > [ Why doesn't dynamic_cast work when I dlopen a
> shared library? ]
> 
> I think the right place for this question might have
> been
> gcc-help (http://gcc.gnu.org/ml/gcc-help/).
> Nevertheless, I think
> http://gcc.gnu.org/faq.html#dso
> should answer your question.
> - Dan
> 
> --
> Wine for Windows ISVs: http://kegel.com/wine/isv


--------------------------------------
STOP HIV/AIDS.
Yahoo! JAPAN Redribbon Campaign 2005
http://pr.mail.yahoo.co.jp/redribbon/


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