Reverse engineering

34 views
Skip to first unread message

Tom Morris

unread,
May 15, 2011, 5:02:44 PM5/15/11
to gaphor-dev
A note a couple of months ago said:

> We're actually looking for something to replace the PyNSource code. If you have any suggestions, please share them.

I'm curious as to why you're replacing it. There don't seem to be
very many options from the lack of response to this thread:
http://groups.google.com/group/comp.lang.python/browse_thread/thread/82b3b24af35bdba0

Pyreverse is probably going to be my next stop to investigate, but I
don't know how it compares to PyNSource

> Now we're on the subject anyway: does anyone have a suggestion for analyzing Java code?

ArgoUML uses the ANTLR Java grammar. ANTLR is usable from most
languages.

Tom

Arjan Molenaar

unread,
May 16, 2011, 11:48:56 PM5/16/11
to gapho...@googlegroups.com

On 15 May 2011, at 23:02, Tom Morris wrote:

> A note a couple of months ago said:
>
>> We're actually looking for something to replace the PyNSource code. If you have any suggestions, please share them.
>
> I'm curious as to why you're replacing it. There don't seem to be
> very many options from the lack of response to this thread:
> http://groups.google.com/group/comp.lang.python/browse_thread/thread/82b3b24af35bdba0
>
> Pyreverse is probably going to be my next stop to investigate, but I
> don't know how it compares to PyNSource

There are some differences in the way the code is handled I thought. At least PyNSource seems like a dead project now.

Some comparison needs to be done. I agree.

>> Now we're on the subject anyway: does anyone have a suggestion for analyzing Java code?
>
> ArgoUML uses the ANTLR Java grammar. ANTLR is usable from most
> languages.

Antlr is just a parser (like Yacc and Bison). If someone already implemented a parser for Java, that would be great :)

Regards,

Arjan

> Tom
>
> --
> You received this message because you are subscribed to the Google Groups "gaphor-dev" group.
> To post to this group, send email to gapho...@googlegroups.com.
> To unsubscribe from this group, send email to gaphor-dev+...@googlegroups.com.
> For more options, visit this group at http://groups.google.com/group/gaphor-dev?hl=en.
>

Tom Morris

unread,
May 17, 2011, 2:43:00 AM5/17/11
to gapho...@googlegroups.com
On Mon, May 16, 2011 at 11:48 PM, Arjan Molenaar <gap...@gmail.com> wrote:
> On 15 May 2011, at 23:02, Tom Morris wrote:
>
>> A note a couple of months ago said:
>>
>>> Now we're on the subject anyway: does anyone have a suggestion for analyzing Java code?
>>
>> ArgoUML uses the ANTLR Java grammar.  ANTLR is usable from most
>> languages.
>
> Antlr is just a parser (like Yacc and Bison). If someone already implemented a parser for Java, that would be great :)

Umm, thanks for the CS101 lesson (I think), but that's why I wrote the
"Java grammar" for ANTLR. ANTLR parser + ANTLR Java grammar == parser
for Java. (ie your "great")

Here are some direct links which will save you having to use a web
search engine:

http://www.antlr.org/grammar/1152141644268/Java.g
http://argouml-java.tigris.org/source/browse/argouml-java/trunk/src/org/argouml/language/java/reveng/Java.g?view=markup

Tom

Arjan Molenaar

unread,
May 17, 2011, 9:10:50 AM5/17/11
to gapho...@googlegroups.com
On Tue, May 17, 2011 at 8:43 AM, Tom Morris <tfmo...@gmail.com> wrote:
> On Mon, May 16, 2011 at 11:48 PM, Arjan Molenaar <gap...@gmail.com> wrote:
>> On 15 May 2011, at 23:02, Tom Morris wrote:
>>
>>> A note a couple of months ago said:
>>>
>>>> Now we're on the subject anyway: does anyone have a suggestion for analyzing Java code?
>>>
>>> ArgoUML uses the ANTLR Java grammar.  ANTLR is usable from most
>>> languages.
>>
>> Antlr is just a parser (like Yacc and Bison). If someone already implemented a parser for Java, that would be great :)
>
> Umm, thanks for the CS101 lesson (I think), but that's why I wrote the
> "Java grammar" for ANTLR.  ANTLR parser + ANTLR Java grammar == parser
> for Java. (ie your "great")

I see Antlr is capable of producing Python code. I did not consider
that option :S
(note to self: I should first check before answering)

On their site they show a lot of grammars it seems. Hmm..

Thanks. Indeed that could save a lot of time.

:)

Thanks. This is worth looking into for sure!

silopolis

unread,
Jul 14, 2011, 11:38:07 AM7/14/11
to gapho...@googlegroups.com
Hi,


Le mardi 17 mai 2011 05:48:56 UTC+2, arjan a écrit :

On 15 May 2011, at 23:02, Tom Morris wrote:

There are some differences in the way the code is handled I thought. At least PyNSource seems like a dead project now.

FYI, last commit is only 6 days old.

And, BTW, congratulations for this nice piece of code.

Bests
Je

Reply all
Reply to author
Forward
0 new messages