[orbitcpp-list] warnings
Status: Beta
Brought to you by:
philipd
|
From: Laszlo M. <las...@et...> - 2000-08-18 09:09:14
|
Hi Folks!
Some days ago I tried to investigate why gcc gives tons of warnings
during compilation of orbitc++ generated stuff. After I found the main
cause (those const/non const cast operators) I looked at some other
orbs how they solve this problem. I found special ifdefs in both mico
and omniorb, unfortunately none of those solutions were 100% perfect.
Anyway when I do something similar for orbitc++, I was not able to
compile everything :(
And unfortunately gcc 2.96 issues these warnings too :(
But there is another kind of warnings, which is caused by this
stuff in pass_stubs.cc:
void IDLPassStubs::doInterface(IDLInterface &iface)
[...]
// make cast operators for all mi base classes
IDLInterface::BaseList::const_iterator
first = iface.m_all_mi_bases.begin(),last = iface.m_all_mi_bases.end();
while (first != last) {
m_header
<< indent << "operator " << (*first)->getQualifiedCPPIdentifier() << " &() {" << endl;
m_header
<< ++indent << "return *" << (*first)->getQualifiedCPPCast("this") << ';' << endl;
m_header
<< --indent << '}' << endl;
first++;
}
Here gcc says, that there is no point to provide
operator Base&()
for the derived classes, because it won't execute them, but do the
right thing itself ;)
So I guess, this code could be safely removed.
Laszlo
|