home *** CD-ROM | disk | FTP | other *** search
- Newsgroups: comp.object
- Path: sparky!uunet!charon.amdahl.com!amdahl!rtech!pacbell.com!ames!saimiri.primate.wisc.edu!zaphod.mps.ohio-state.edu!sol.ctr.columbia.edu!The-Star.honeywell.com!umn.edu!news
- From: burchard@horizon.math.utah.edu (Paul Burchard)
- Subject: Re: Procedures and their instances (objects in traditional OO languages)
- Message-ID: <C1JMHB.EC6@news2.cis.umn.edu>
- Sender: news@news2.cis.umn.edu (Usenet News Administration)
- Nntp-Posting-Host: dialup-slip-1-42.gw.umn.edu
- Organization: University of Minnesota
- References: <PCG.93Jan27160420@csthor.aber.ac.uk>
- Date: Thu, 28 Jan 1993 02:48:43 GMT
- Lines: 105
-
- In article <PCG.93Jan27160420@csthor.aber.ac.uk> pcg@aber.ac.uk (Piercarlo
- Grandi) writes:
- > pcg> In particular they show that (in class based OO languages) classes
- > pcg> are procedures, and objects are procedure instances; closures if
- > pcg> the language is a traditional OO one, and continuations if the
- > pcg> language is an actor OO one.
- >
- > Davis> Classes and objects are not procedures;
- >
- > First, this is not what I wrote; I wrote:
- >
- > pcg> (in class based OO languages) classes are procedures, and objects
- > pcg> are procedure instances
- >
- > Both the qualification in parenthesis and the dictinction between
- > procedures and procedure instances are important (even if for the sake
- > of extreme brevity, and I regret that, I did not make the first explicit
- > in the very short frase: "More precisely objects are values of a
- > procedure instance (closure/continuation) record type.").
- >
- > Second, classes and objects are procedures and procedure instances in
- > two very real senses; that this is how historically they were
- > 'invented', both in capability systems (the PDP-1) and in OO languages
- > (Simula 67); and that this is how they actually behave, even if this is
- > disguised by syntax and foggy terminology (the very special status of a
- > C++ constructor can only be fully understood if it is considered the
- > body of its class seen as a procedure, and even its invocation syntax is
- > inspired to that).
-
- Interestingly, the procedure view of classes is very natural and helpful for
- modeling abstract mathematical concepts in an organized way. I have developed
- a math <--> OOP dictionary taking advantage of this; an outline is given in
- the table below:
-
- Math OOP
- -------- ---------
- category protocol/signature (object type based on
- functionality rather than inheritance)
- specific construction
- of objs in category class/implementation conforming to protocol
-
- functor class whose constructor applies the functor by
- accepting args in other categories
-
- In particular, the most interesting classes are those which act as functors,
- or more precisely, whose constructors act as functors. A functor is thought
- of as a specific way of constructing objects in its target category; this
- is exactly the role of a class in the dictionary.
-
- --
- --------------------------------------------------------------------
- Paul Burchard <burchard@geom.umn.edu>
- ``I'm still learning how to count backwards from infinity...''
- --------------------------------------------------------------------
-
-
-
-
-
-
-
-
-
-
-
-
- ocedures and procedure instances are important (even if for the sake
- > of extreme brevity, and I regret that, I did not make the first explicit
- > in the very short frase: "More precisely objects are values of a
- > procedure instance (closure/continuation) record type.").
- >
- > Second, classes and objects are procedures and procedure instances in
- > two very real senses; that this is how historically they were
- > 'invented', both in capability systems (the PDP-1) and in OO languages
- > (Simula 67); and that this is how they actually behave, even if this is
- > disguised by syntax and foggy terminology (the very special status of a
- > C++ constructor can only be fully understood if it is considered the
- > body of its class seen as a procedure, and even its invocation syntax is
- > inspired to that).
-
- Interestingly, the procedure view of classes is very natural and helpful for
- modeling abstract mathematical concepts in an organized way. I have developed
- a math <--> OOP dictionary taking advantage of this; an outline is given in
- the table below:
-
- Math OOP
- -------- ---------
- category protocol/signature (object type based on
- functionality rather than inheritance)
- specific construction
- of objs in category class/implementation conforming to protocol
-
- functor class whose constructor applies the functor by
- accepting args in other categories
-
- In particular, the most interesting classes are those which act as functors,
- or more precisely, whose constructors act as functors. A functor is thought
- of as a specific way of constructing objects in its target category; this
- is exactly the role of a class in the dictionary.
-
- --
- --------------------------------------------------------------------
- Paul Burchard <burchard@geom.umn.edu>
- ``I'm still learning how to count backwards from infinity...''
- --------
-