[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[wishlist]



Hi,

I'm using SableCc in my application to generate a compiler.

I think SableCc is a brilliant work of art. Wonderful design principles. I
will never go back to Lex, Yacc or their progenity. In my opinion SableCc
also beats CUP. There is one feature in CUP, however, that attracts me as
well: the ability to dump human-readable lexer and parser tables. That's a
nifty feature as well. It allows for deep analysis of ugly shift/reduce or
even worse, reduce/reduce issues. But then again, even then I consider
SableCc to be the most user-friendly and intelligent LALR(1)
compiler-compiler around.

Now, I have a small request.

When I document my code, I usually add a file package.html at the root of
the namespace, briefly describing the content and purpose of the namespace.
I'd like to add one for the namespaces generated by SableCc, i.e., the
analysis, lexer, node, and parser namespaces. Otherwise no description will
show up in the javadoc API index file. However, because these packages are
generated, I need to get rid of their folders when I do an "ant clean", and
subsequently re-generate the packages. You can't eternally avoid cleaning up
:)

Is it possible for SableCc to take responsibility to generate a
"package.html" in the folders that it generates?

It should only contain one or two sentences saying: "This package was
generated by SableCc. It contains the compiler's lexer.", or something along
these lines. In such case I wouldn't have to worry by myself as to how to
document these packages.

Now, I could easily add such support by myself, with an ugly hack somewhere
in between lines 157 to 208 of org.sablecc.sablecc.SableCC, but I'd rather
avoid retrofitting continuously such hack on new versions of SableCc.

Greetings
Erik Poupaert