This is the mail archive of the
gcc@gcc.gnu.org
mailing list for the GCC project.
Re: -Wabi is misdesigned (answers the wrong question)
On Fri, 2003-10-24 at 11:30, Richard Henderson wrote:
> On Fri, Oct 24, 2003 at 10:59:52AM -0700, Mark Mitchell wrote:
> > It's probably possible to do what Joe wants, but it's not trivial. One
> > would have to be very careful not to have the first layout algorithm
> > bias the results of the second; after running the first, you'd want to
> > clear out the layout entirely and do it again.
>
> Shouldn't it be possible to copy the whole tree before laying it
> out the first time? That would (1) solve the pollution problem
> and (2) give you something to compare against to see if they differ.
That's certainly the right approach.
It's just that I'm not 100% sure you can copy all these things easily.
The other problem is that it's not clear to me that this approach gives
you the completely right answer either. It tells you when something is
different -- but not when a chance will result in some derived class
being different. There are actually a fair number of places where 3.2
would do the same thing with the base class -- but some follow-on
derived class would differ.
--
Mark Mitchell <mark@codesourcery.com>
CodeSourcery, LLC