To LUGNET HomepageTo LUGNET News HomepageTo LUGNET Guide Homepage
 Help on Searching
 
Post new message to lugnet.roboticsOpen lugnet.robotics in your NNTP NewsreaderTo LUGNET News Traffic PageSign In (Members)
 Robotics / 21665
21664  |  21666
Subject: 
Re: Are there GOTO statements in NQC?
Newsgroups: 
lugnet.robotics
Date: 
Fri, 21 Nov 2003 03:31:22 GMT
Original-From: 
Jim Choate <RAVAGE@EINSTEINnomorespam.SSZ.COM>
Viewed: 
1141 times
  
On Fri, 21 Nov 2003, Brian B. Alano wrote:

Don't know about C/C++, but IIRC in Java the garbage collector destroys objects
not when they are out of scope, nor when their creator function exits. It
destroys them when the object is no longer referenced by any threads. That is to
say, if there's no variable or other object holding a reference to the object,
then the object is inaccessible, so it might as well be killed.

T. Alexander Popiel wrote:
Out of curiosity, is a destructor for an object supposed to be called
when the variable goes out of scope, or when the function that it's
allocated in ends?  This can be different if the variable is declared
in a nested block, instead of at the top of the function.  I think I've
seen both in C implementations...  The many ways this could have
significant effect on the result are left as an exercise to the reader.

The purpose of garbage collection is to remove resources from use when
they are not going to be used anymore. It covers a variety of issues, some
you've each touched on.

I suggest as a start,

Garbage Collection: Algorithms for automatic dynamic memory management.
Jones, Lins

-- --

Open Forge, LLC  24/365 Onsite Support for PCs, Networks, & Game Consoles
512-695-4126 (Austin, Tx.)  help@open-forge.com  irc.open-forge.com

Hangar 18  Open Source Distributed Computing Using Plan 9 & Linux
512-451-7087  http://open-forge.org/hangar18  irc.open-forge.org

James Choate  512-451-7087  ravage@ssz.com  jchoate@open-forge.com



Message is in Reply To:
  Re: Are there GOTO statements in NQC?
 
Don't know about C/C++, but IIRC in Java the garbage collector destroys objects not when they are out of scope, nor when their creator function exits. It destroys them when the object is no longer referenced by any threads. That is to say, if (...) (21 years ago, 21-Nov-03, to lugnet.robotics)

19 Messages in This Thread:









Entire Thread on One Page:
Nested:  All | Brief | Compact | Dots
Linear:  All | Brief | Compact
    

Custom Search

©2005 LUGNET. All rights reserved. - hosted by steinbruch.info GbR