Re: Garbage collection problem

From: Chris Smith (cdsmith_at_twu.net)
Date: 03/11/04


Date: Wed, 10 Mar 2004 20:29:45 -0700


"Dale King" <kingd[at]tmicha[dot]net> wrote:
> > A reachable object is any object that can be accessed in any potential
> > continuing
> > computation from any live thread.
>
> Here is one of the unclear parts. What does *can be* accessed mean. Does
> *can* be accessed require that it *will* be accessed. Or is *could have*
> been sufficient.

Dale,

I'm jumping in a bit late just to clarify something and avoid confusion.
I'm reading this thread with interest.

There are, as far as I can see, two reasonable choices for interpreting
the JLS's "can be accessed" in the phrase above. Certainly, the phrase
"could have been accessed" is one of them. However, the phrase "will be
accessed" is not one of them. There are any number of situations in
which the JRE can't reasonably determine, or it's just plain
indeterminate, whether an object will be accessed; for example, when
there are still references in scope but future behavior depends on user
input. Getting the JRE to determine "will be accessed" is clearly
beyond the scope of any specification.

The other reasonable interpretation (besides your own) is simply to
interpret "can be accessed" as referring to the set of possible
behaviors of the program right now, versus what it could have been
written to do in the past. I can't think of a replacement for the "can
be accessed" phrase that more clearly defines this. I think "can be
accessed" says it very clearly already -- but that, of course, is the
whole point of the disagreement.

-- 
www.designacourse.com
The Easiest Way to Train Anyone... Anywhere.
Chris Smith - Lead Software Developer/Technical Trainer
MindIQ Corporation


Relevant Pages

  • Re: Todays xkcd
    ... Sam Nelson wrote: ... considered, it seems, to have a job a) terribly narrow in scope and ... adequately described by the phrase `knows how to program a computer'. ...
    (uk.misc)
  • Re: issues with exact phrase searching
    ... FROM SCOPE() WHERE CONTAINS AND (Filename ... with the phrase "computer's technology" in them. ... whose SQL looks like: ...
    (microsoft.public.sqlserver.fulltext)
  • issues with exact phrase searching
    ... I'm finding that using CONTAINS and any word or phrase containing ... FROM SCOPE() WHERE CONTAINS > 0 ... properly when it's "computer technology", whose SQL looks like: ...
    (microsoft.public.sqlserver.fulltext)