From: David Gudeman
Subject: Re: FIRST CLASS definition
Date: 
Message-ID: <GUDEMAN.95Apr5092607@baskerville.cs.arizona.edu>
In article <··········@gap.cco.caltech.edu> ···@asgard.srl.caltech.edu (Jay Cummings) writes:

]Patrick D. Logan (···············@ccm.jf.intel.com) wrote:
]:In article <······················@lugb.latrobe.edu.au> Douglas Moore writes:

]: >(a) What is your preferred definition of first classness?

]: An object that can exist without a name and be referenced directly by any** 
]: other object is a "first class" object.

]Um, how can it fufil the second criterion, being referenced, and still fufil
]the first, possibly not having a name?  How can an object without a name
]be referenced?

No offense to Chris, but his definition does not capture the concept
of first-classness.  Numbers have names, yet they are usually thought
of as first class.  In fact programming languages often have some way
of naming most of their first class objects.

I would say that an object is first class if

(1) It can be passed to functions and returned from functions.

and

(2) The object can be constructed dynamically.

(Actually, (2) needs to be elaborated considerably to avoid tricky
interpretations that violate what it is meant to express.)

By the way, none of the newsgroups in the subject line is really
appropriate for this discussion.  A better group would be
comp.lang.misc or comp.lang.lisp.  I have directed followups to
comp.lang.misc.
--
					David Gudeman
·······@cs.arizona.edu

From: Patrick D. Logan
Subject: Re: FIRST CLASS definition
Date: 
Message-ID: <patrick_d_logan.256.0009BBBC@ccm.jf.intel.com>
In article <····················@baskerville.cs.arizona.edu> ·······@cs.arizona.edu (David Gudeman) writes:

>Numbers have names, yet they are usually thought
>of as first class.  In fact programming languages often have some way
>of naming most of their first class objects.

The *ability* to have a name and the *requirement* to have a name are two 
different things.

I know of no programming language that *requires* numbers to have names before 
they can be used.

There are plenty of languages that *require* functions to have names before 
they can be used.

What if you had to assign a name to every number before it could be used?

define one = 1;
define two = 2;
return one + two;

Would you rather do that or do:

return 1 + 2;

I ask you? Really!


···············@ccm.jf.intel.com
Intel/Personal Conferencing Division
(503) 264-9309 FAX: (503) 263-3375

"In doing this we fall into a trap that Alexander 
wants us to avoid: separating design from construction."
-Richard P. Gabriel, Critic-At-Large
From: Simon Brooke
Subject: Re: FIRST CLASS definition
Date: 
Message-ID: <D6ww3s.2tn@rheged.dircon.co.uk>
I'm not pretending I have anything useful to contribute to this
discussion; more nit-picking,really.

In article <····················@baskerville.cs.arizona.edu>,
David Gudeman <·······@cs.arizona.edu> wrote:

>No offense to Chris, but his definition does not capture the concept
>of first-classness.  Numbers have names, yet they are usually thought
>of as first class.  In fact programming languages often have some way
>of naming most of their first class objects.
>
>I would say that an object is first class if
>
>(1) It can be passed to functions and returned from functions.
>
>and
>
>(2) The object can be constructed dynamically.

This seems a bit odd. Numbers can be constructed dynamically? I'm no
platonist, but I'm not happy with this. It doesn't seem to me that a
number can be constructed at all.

Perhaps it would be useful to define 'first class' not in terms of
principles but in terms of pragmatics. What we mean by 'first class'
is something whose increase will not be eaten by the caterpillar, or
rather, whose semantics will not be eaten by the garbage collector.

Isn't it?

-- 
------- ·····@rheged.dircon.co.uk (Simon Brooke)

			-- mens vacua in medio vacuo --