home *** CD-ROM | disk | FTP | other *** search
/ NetNews Usenet Archive 1992 #19 / NN_1992_19.iso / spool / comp / object / 3396 < prev    next >
Encoding:
Internet Message Format  |  1992-09-02  |  1.9 KB

  1. Xref: sparky comp.object:3396 comp.lang.clos:774
  2. Newsgroups: comp.object,comp.lang.clos
  3. Path: sparky!uunet!sun-barr!decwrl!csus.edu!netcom.com!objsys
  4. From: Bob Hathaway <objsys@netcom.com>
  5. Subject: Re: Object-Oriented Methodologies - Class Specifications
  6. Message-ID: <j8knsmd.objsys@netcom.com>
  7. Date: Thu, 03 Sep 92 00:23:42 GMT
  8. Organization: Object Systems
  9. References: <1992Sep2.140048.11829@bcrka451.bnr.ca> <BtyJK8.GFH@rice.edu> <j1kn6ll.objsys@netcom.com>
  10. Followup-To: comp.object
  11. Lines: 26
  12.  
  13. In article <j1kn6ll.objsys@netcom.com> Bob Hathaway <objsys@netcom.com> writes:
  14. >>...
  15. >>        INTERSECT((x, LINE) (y, CIRCLE))
  16. >
  17. >In "OOP" the INTERSECT function could be made a "friend" of LINE and CIRCLE
  18. >granting INTERSECT access to both classes without violating a strong form of
  19. >encapsulation.  Perhaps "strict OO messaging" could be substituted for "OOP".
  20. >But I'd keep in mind that such implementation access isn't always a good thing.
  21.  
  22. I may have jumped the gun.  Simple functions can do the trick; access via
  23. a "friend" mechanism is only required for accessing an implementation (which
  24. is an efficiency trick and disastrous for multiple implementations).  But I
  25. still don't understand why people think functions in CLOS are special;
  26. except for their left-to-right ordering and lack of default protection for
  27. their arguments they're still just ordinary polymorphic functions invoked at
  28. run-time.  Maybe the run-time function invocation not being so commonly
  29. available explains why this is considered special (and is to CLOS' credit).
  30. But the lack of default protection means no multiple-implementations per
  31. type; a severe restriction that I doubt even CLOS' intercessory protocols
  32. can overcome.  Am I wrong here?  Can CLOS provide for the separation of
  33. types and classes (or any kind of multiple implementations per type)?
  34.  
  35. bob
  36. objsys@netcom.com
  37.  
  38. P.S.  Going typeless is not an acceptable answer.
  39.