This is the mail archive of the
gcc-help@gcc.gnu.org
mailing list for the GCC project.
Mixing -frtti and -fno-rtti code in the same executable
- From: Jonathan Lennox <lennox at cs dot columbia dot edu>
- To: gcc-help at gcc dot gnu dot org
- Date: Tue, 27 Jan 2004 11:41:30 -0500
- Subject: Mixing -frtti and -fno-rtti code in the same executable
In one executable, is it safe to mix C++ object files compiled with -frtti
and -fno-rtti, assuming that objects instantiated in -fno-rtti sections
don't leak into code that uses typeid or dynamic_cast<>?
I'm porting a library of ours to the Sharp Zaurus, whose GUI libraries are
all compiled with -fno-exceptions -fno-rtti. The code uses
boost::shared_ptr<>, however, which doesn't work without RTTI. Am I going
to have to hack boost somehow, or can I get away with this?
Thanks.
--
Jonathan Lennox
lennox at cs dot columbia dot edu