[plt-scheme] instantiating another instance of same class

From: Neil W. Van Dyke (neil at neilvandyke.org)
Date: Wed Apr 9 12:48:39 EDT 2003

Matthew Flatt <mflatt at cs.utah.edu> writes at 10:11 09-Apr-2003 -0600:
> We don't want to hand out the ability to instiantiate a class whenever
> we hand out an instance of the class.

OK, that makes a lot of sense to me, at least wrt a top-level
`get-class-of-object' procedure.

One more question: Are there cases in which the class of an instance
must be hidden from *methods of its superclass*?

(As far as I know, a user can't define a class without already knowing
the superclass and being able to capture the class being defined.  If
that's true, then that leaves only the question of whether a superclass
can know a subclass.)


Posted on the users mailing list.