[ast-optimizer-branch]: Your change to c-pretty-print.c is broken.

Frank Ch. Eigler fche@redhat.com
Mon Jun 17 03:35:00 GMT 2002


Hi -

dberlin wrote:

> > I'm planning to commit the following patch.  It fixes the printing of
> > expressions [...]
> > where the 8/7 indices were not both correctly printed because the
> > size of the pointed-to type was accounted for improperly.
> 
> However, it broke some printing [completely]. [...]

Right, Diego came across the problem on Friday.  I'll submit a patch today
that guards against that division-by-zero.  I'd have done it earlier, but
in the process, I ran into an annoying fact about the tree representation
of pointer-typed INT_CST nodes.  That is that their values cannot be
unambiguously pretty-printed by looking at the INT_CST value/type 
locally, since ints cast to pointers are altered differently from ints
added to pointers.  Working around this has been taking a little more time.


- FChE



More information about the Gcc-patches mailing list