FW: [antlr-interest] got new "language implementation" lectur e au dio up
Matt Benson
gudnabrsam at yahoo.com
Wed Feb 19 14:31:54 PST 2003
Not sure what you mean by "smart IDEs", but my
longtime goal is to implement a good, strong, portable
Java analysis library that can be used for code
completion, among other things.
-Matt
--- Jim O'Connor <Jim.OConnor at microfocus.com> wrote:
> Hi Matt,
> It has many features that my Java analysis tool
> needs. It parses a Java
> file (Grammar). It creates a symbol table (resolves
> types/variables/methods). With the Antlr grammar, I
> can construct an AST
> for any number of purposes. The JavaSrc code
> creates HTML pages similar to
> JavaDoc. The HTML creation is a nice sidelight to
> view the initial work but
> may not be useful for all purposes.
>
> I would like to incorporate the symbol table
> information with the AST
> information to create a local database for each java
> file, class or other
> "destinct module", whatever that means. The AST
> allows navigation throught
> the parse tree but doesn't tell me (quickly) where
> the class ACCOUNT is
> used throughout the file. Where is the method
> ACCOUNT.balance() used?
>
> My current strategy is to
>
> A. parse lots of java files
> B. save off XML representations of each AST
> c. gather the symbol table information
> D. resolve type/variable/methods
> E. ?write out the symbol table information?
> F. read in an AST
> 1. Match the AST with Symbol table information
> 2. Create a sorted "local database" for each AST
> G. Re-work names/coarse grained items for easy
> lookup.
>
>
> The "click the links" javadoc approach is a valuable
> tool. My goal is a
> more interactive fine grained query at fast speeds.
> With a database that
> can support these queries, I will be able to solve
> the year 10,000 problem
> in Java code. Where are all date fields that use
> just four characters to
> represent a year?
>
> Jim
>
> P.S. If you can tell me how "smart" IDEs work, I'm
> all ears.
>
>
>
> -----Original Message-----
> From: Matt Benson [mailto:gudnabrsam at yahoo.com]
> Sent: Wednesday, February 19, 2003 3:51 PM
> To: antlr-interest at yahoogroups.com
> Subject: Re: FW: [antlr-interest] got new "language
> implementation"
> lecture au dio up
>
>
> I have never heard of this thing until now. This is
> right along the lines of what I have been looking
> for/working with. For what purpose are you wanting
> to
> use this code, Jim?
>
>
> --- Jim O'Connor <Jim.OConnor at microfocus.com> wrote:
> >
> > Hi Terence,
> > I've been through the "JavaSrc"
> > http://home.austin.rr.com/kjohnston/javasrc.htm
> > implementation of a symbol
> > table. It originated with the four part series of
> > articles
> >
>
http://developer.java.sun.com/developer/technicalArticles/Parser/SeriesPt4/.
> > I assume you are familiar with it. ;)
> >
> > I have two questions that come from different
> > "ends". The first is the
> > step-by-step reasoning. Where should I jump in to
> > define objects that
> > contain the necessary information? (example,
> > JavaToken, ClassDef, etc...).
> > The "other end" is a consideration of intermediate
> > forms. I have a lot of
> > .java files. "JavaSrc" makes two passes saving
> off
> > reference.txt for
> > particular directories. What is the plan with
> > memory considerations? Can
> > XML be used for intermediate forms? I have had
> > little "luck" trying to
> > implement/understand XTAL to make it effective.
> >
> > Another question. What about imports? Jar
> files?
> > Can introspection be
> > used?
> >
> > Jim
> >
> >
> >
> >
> >
> >
> >
> > -----Original Message-----
> > From: Terence Parr [mailto:parrt at jguru.com]
> > Sent: Tuesday, February 18, 2003 1:47 PM
> > To: antlr-interest at yahoogroups.com
> > Subject: Re: [antlr-interest] got new "language
> > implementation" lecture
> > audio up
> >
> >
> >
> > On Tuesday, February 18, 2003, at 10:42 AM, Matt
> > Benson wrote:
> >
> > > Just curious... when do symbol tables come up?
> > and
> > > can TreeParsers be used in any direct/helpful
> way
> > to
> > > generate them?
> >
> > Hi Matt,
> >
> > I was going to do sym tabs tomorrow, but must do
> GC
> > real quick and then
> > get the folks started on ANTLR itself. Plus, I
> want
> > to think more
> > about sym tab stuff before presenting. Now is the
> > time to tell me
> > precisely what you want to learn about in that
> > regard! ;)
> >
> > Ter
> > --
> > Co-founder, http://www.jguru.com
> > Creator, ANTLR Parser Generator:
> > http://www.antlr.org
> > Lecturer in Comp. Sci., University of San
> Francisco
> >
> >
> >
> >
> > Your use of Yahoo! Groups is subject to
> > http://docs.yahoo.com/info/terms/
> >
> >
> >
> >
> > Your use of Yahoo! Groups is subject to
> > http://docs.yahoo.com/info/terms/
> >
> >
>
>
> __________________________________________________
> Do you Yahoo!?
> Yahoo! Shopping - Send Flowers for Valentine's Day
> http://shopping.yahoo.com
>
>
>
> Your use of Yahoo! Groups is subject to
> http://docs.yahoo.com/info/terms/
>
>
>
>
> Your use of Yahoo! Groups is subject to
> http://docs.yahoo.com/info/terms/
>
>
__________________________________________________
Do you Yahoo!?
Yahoo! Shopping - Send Flowers for Valentine's Day
http://shopping.yahoo.com
Your use of Yahoo! Groups is subject to http://docs.yahoo.com/info/terms/
More information about the antlr-interest
mailing list