[antlr-interest] Newbie re: memory management on parse fail (C++) and Java

Matthew Ford Matthew.Ford at forward.com.au
Wed Oct 10 16:00:21 PDT 2001


Has anyone check for memory leaks in the Java version?

I know Java has automatic garbage collection but if the references to
objects are not handled correctly you end up with old unused objects trapped
in memory because of a  reference that has not been cleaned up.

matthew
----- Original Message -----
From: "John Green" <greenj at ix.netcom.com>
To: <antlr-interest at yahoogroups.com>
Sent: Thursday, October 11, 2001 8:30 AM
Subject: RE: [antlr-interest] Newbie re: memory management on parse fail
(C++)


> I find it to be good. Some of our regression tests parse thousands of
small
> programs, taking an hour or so to do all of the parsing. No memory
troubles.
> I do watch it carefully, and I have used a couple of leak detection tools
> against it as well.
>
> With regards to errors: I haven't specifically watched the memory when
we've
> parsed programs with errors, but for what it's worth, I haven't noticed
any
> memory leaks.
>
> The only memory trouble I have had: the hidden tokens weren't being
cleaned
> up after a parse, so I had to write my own functions for doing that clean
up
> job. But, you probably won't be using the hidden tokens (preserving
> whitespace) feature.
>
> Cheers,
> John
>
>
> > -----Original Message-----
> > From: James Mansion [mailto:james at westongold.com]
> > Sent: Thursday, October 11, 2001 12:34 AM
> > To: antlr-interest at yahoogroups.com
> > Subject: [antlr-interest] Newbie re: memory management on parse fail
> > (C++)
> >
> >
> > Some parser systems I've tinkered with have been
> > somewhat careless about recovering memory, particularly
> > in cases where there has been a parsing or scanning
> > error.
> >
> > Is the C++ code generated pretty good about this sort of
> > thing?
> >
> > I want to parse interective input (which will be bad, often)
> > in a long-running process.
> >
> > Cheers,
> > James
> >
> >
> >
> >
> > Your use of Yahoo! Groups is subject to
http://docs.yahoo.com/info/terms/
> >
> >
>
>
> _________________________________________________________
> Do You Yahoo!?
> Get your free @yahoo.com address at http://mail.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/ 



More information about the antlr-interest mailing list