A question about tree-pretty-printing

Richard Kenner kenner@vlsi1.ultra.nyu.edu
Mon Jun 28 18:19:00 GMT 2004


    I think the consensus is that tree-pretty-printing looks C-like.

I agree with that as well

    As for diagnostics, I think I'll stick to C, C++, Java -- but encourage
    other front-ends maintainers to share infrastructure with the main
    diagnostic and pretty-printing machinery.

I think it's harder than it seems.  pretty-printing seems intrinsically
language-dependent, so I don't see a way to share that if the idea is to
write in the syntax of the other language.  As far as diagnostics, I 
agree that some sharing is good, but often the other language will have
an entirely different internal tree structure than that GCC tree and
it's usually most beneficial for good error message generation to do so
from those trees.



More information about the Gcc mailing list