Re: Variables

Robert DiFalco ([email protected])
Fri, 2 Jun 1995 18:40:55 -0700


>
>Intriguing. More examples?
>

I can't think of anymore right now, other than the syntax examples I left in
another message.

>I don't think that's really fair. Classes have a real runtime
>existence in any language that permits dynamic instantiation (which
>includes every language I can think of off the top of my head).

No, you're right. Atleast for languages starting with Simula going into ones
like Smalltalk, Ada, CLOS, Oberon, even SELF and such that have metaclasses,
I was taking more of the Eiffel, C++, Objective-C view. Not that it is
better, its just simpler to explain and since we are not designing a
language I woosed out. I didn't want to go into a description of
metaclasses. I'll revise what I said to be that I generally think of a class
as something used to instantiate objects or classify functionality (such as
an abstract class that is not meant to be instantiated).

>The
>*purpose* of a class is to define a template for a collection of
>related, usually parameterized objects. (And generally with a
>programmatic interface; we'll get to *that* with behaviours.) That
>seems to match the notion here pretty well, IMO.

Save that there is no parameterization, that is why it seems more like a
variable or object name to me.

>Well, there are some ways I disagree. First, IceCreamCone is *not*
>itself a renderable object in the graph -- it's much closer to the
>concept of the "PASSIVE DEF"'ed objects just proposed.

What if it were rendered. That doesn't seem to change the purpose to me,
only whether it was passively done or not. In a very real sense you are
assigning to a variable what is on the left side of IceCreamCone.

>
>But it *does* have them -- specifically, the radius and height
>parameters. I don't see what these are if *not* slots; they match
>the concept quite well.
>

Ah, then I misunderstood the example. IceCreamCone actually becomes a new
"Node" *type*? Are you sure? I thought the example was for just naming it so
it could be used "as is" in (.wrl) files. If I misunderstood, forget all my
comments, this is a whole 'nuther subject that I wasn't addressing in my
message.

>I don't think I'm understanding you -- if I grok the original proposal,
>IceCreamCone is intended for *just* instantiation. I think I see what
>you're saying, but I think that either one or the other of us is
>misunderstanding Nathan's proposal. (Specifically, I think you may
>actually *be* talking about variables -- but I don't *think* Nathan
>was...)

Given that Nathan mentioned variables, I just assumed that is what he meant.
I guess he should jump in right about now and clarify as to whether he was
talking about creating new types (that either do or don't support
inheritance) or naming objects in a similar fashion to the DEF keyword.

Robert