Relay-Version: version B 2.10 5/3/83; site utzoo.UUCP Path: utzoo!mnetor!seismo!rutgers!ucla-cs!cit-vax!elroy!jplgodo!wlbr!scgvaxd!trwrb!aero!aero2!obrien From: obrien@aero2.ARPA (Michael O'Brien) Newsgroups: comp.lang.smalltalk Subject: Re: finding instances Message-ID: <386@aero2.ARPA> Date: Wed, 24-Jun-87 11:31:20 EDT Article-I.D.: aero2.386 Posted: Wed Jun 24 11:31:20 1987 Date-Received: Fri, 26-Jun-87 07:09:41 EDT References: <470@cup.portal.com> <359f3397.1d22@apollo.uucp> Reply-To: obrien@aero2.UUCP (Michael O'Brien) Distribution: world Organization: The Aerospace Corporation, El Segundo, CA Lines: 44 In article <359f3397.1d22@apollo.uucp> wyant@apollo.UUCP (Geoffrey Wyant) writes: > > > I am having trouble finding the names of instances > > I created under Smalltalk/V. Is there a procedure > > that does this ? or must I document every instance > > I create ? > > This is sort of like asking for the name of everything pointed > at in C program. Instances don't have names, per se. Like > pointers, they maybe assigned to variables or fields within > records. If you just create them without assigning them > to anything, they are inaccessible, just like a pointer to > malloc'ed storage that you didn't assign to anything. This points out something I have been noticing for some time: the near-complete absence of any sort of general interactive (or even batch!) tools for dealing with object memories. [Presumably the person in question is trying to delete a class. You can't delete a class, at least in DigiTalk Smalltalk, if it has instances.] Berkeley Smalltalk (BS II) at least has a way to talk directly to the VM and give it simple commands, outside of the Smalltalk environment. One of these commands causes an integrity check of object memory - not a bad idea in a research machine! Xerox PS has no such facility. Nor has any version of Smalltalk I've ever seen had any real tools for characterizing the contents of object memory. This person's problem could be solved if there were some utility giving a chain back to something understandable that appeared on the screen ("attached to a window in Project foo" or "attached to This Window Here [big flashing arrow]"). The UNIX environment is externalized completely: each object in it has pretty much a directly accessible handle in some space (file names, machine addresses, etc.). This is not true in object memories...yet. Now I'll grant that being able to depress this kind of stuff is the whole and entire point of object-oriented programming! However, if you can't get hold of this kind of information AT ALL you may be up the creek, like the person at the top of this message who kicked this off. -- -------- Mike O'Brien obrien@aerospace.aero.org aero!obrien