Re: general performance question
- From: Knute Johnson <nospam@xxxxxxxxxxxxxxxxxxxxxxx>
- Date: Thu, 31 Jan 2008 09:04:07 -0800
Lasse Reichstein Nielsen wrote:
Knute Johnson <nospam@xxxxxxxxxxxxxxxxxxxxxxx> writes:
Mike Schilling wrote:...if (condition)
{
LargeObject lg = new LargeObject();
lg.doStuff()
// See discussion below
}
I don't think that is true. If you create an Object in a loop and
then reassign another Object to the same reference in the loop, the
first Object is eligible for garbage collection (and will be).
The previous poster didn't mention loops, merely a nested block
scope.
For a loop, the value set in the last iteration also leaks the
block.
/L
How can it if the reference is created in the block?
--
Knute Johnson
email s/nospam/knute/
--
Posted via NewsDemon.com - Premium Uncensored Newsgroup Service
------->>>>>>http://www.NewsDemon.com<<<<<<------
Unlimited Access, Anonymous Accounts, Uncensored Broadband Access
.
- Follow-Ups:
- Re: general performance question
- From: Mike Schilling
- Re: general performance question
- References:
- general performance question
- From: Tobi
- Re: general performance question
- From: Matt Humphrey
- Re: general performance question
- From: Mike Schilling
- Re: general performance question
- From: Knute Johnson
- Re: general performance question
- From: Lasse Reichstein Nielsen
- general performance question
- Prev by Date: Re: How to execute Jar file using Batch file.
- Next by Date: Currency Symbol in JTable
- Previous by thread: Re: general performance question
- Next by thread: Re: general performance question
- Index(es):
Relevant Pages
|