home *** CD-ROM | disk | FTP | other *** search
/ NetNews Usenet Archive 1992 #30 / NN_1992_30.iso / spool / comp / object / 4552 < prev    next >
Encoding:
Internet Message Format  |  1992-12-16  |  2.8 KB

  1. Path: sparky!uunet!cs.utexas.edu!sdd.hp.com!saimiri.primate.wisc.edu!ames!olivea!spool.mu.edu!sgiblab!nec-gw!nec-tyo!wnoc-tyo-news!etl.go.jp!ume!crimson!kekux!s.u-tokyo!is.s.u-tokyo!jeff
  2. From: jeff@is.s.u-tokyo.ac.jp (Jeff McAffer)
  3. Newsgroups: comp.object
  4. Subject: Re: Object hidden state and side effects
  5. Message-ID: <1992Dec16.65250.10645@kei.is.s.u-tokyo.ac.jp>
  6. Date: 16 Dec 92 06:52:43 GMT
  7. References: <1992Dec11.163449.18439@crd.ge.com> 
  8.     <1992Dec13.152136.16852@hasler.ascom.ch> 
  9.     <1992Dec14.112222.13987@kei.is.s.u-tokyo.ac.jp> 
  10.     <1992Dec15.014420.6604@midway.uchicago.edu>
  11. Sender: news@kei.is.s.u-tokyo.ac.jp (Usenet News System)
  12. Reply-To: jeff@is.s.u-tokyo.ac.jp
  13. Organization: University of Tokyo, tcejorP Project.
  14. Lines: 47
  15.  
  16. In article <1992Dec15.014420.6604@midway.uchicago.edu> dave@alex.uchicago.edu (Dave Griffith) writes:
  17.  
  18. { whole bunch of stuff about modelling deleted }
  19.  
  20.  |>If the bits can change and move, then I don't see the diff between
  21.  |>"value" and "object that does not change".  In short, why can't a
  22.  |>value be an object?  What does explicitly knowing/using the fact that
  23.  |>something does not change help us?
  24.  |
  25.  |It _does_ allow a lot of optimization.  There are occasions where copy
  26.  |semantics are cheaper than reference semantics.  But at a higher level, it 
  27.  |seems to be necessary to allow safe programming.  We need to know that noone 
  28.  |can subclass our Integer class so as to allow the old Fortranism of changing 
  29.  |3 to 5.
  30.  
  31. I realize that it allows optimizations but to be honest, from a
  32. programming/design point of view I don't want to know about the
  33. implementation.  That is what we are fighting against.  Having to know
  34. and explicitly use implementation detail.
  35.  
  36. I feel sort of like there is misunderstanding in this thread.  At some
  37. point someone said that a value is not an object (or something like
  38. that) and that it was bad to 'pretend' that it is.  Was that you?  Do
  39. you agree with the statement?  If so why?
  40.  
  41. I am really at a loss here.  What exactly (in concrete real terms) do
  42. you expect people to do differently when using true for example once
  43. it is recognized as a value and not an object?
  44.  
  45.  |Whether the actual bits are changable is rather beside to point.  The idea
  46.  |is that a values essential nature cannot change, whatever that means.  This
  47.  |is usually easiest if the bits are unchanging, but that is not necessary.
  48.  
  49.  
  50. If you want to have "essentially the same" objects great!  That's just
  51. a differnt kind of object.  Perhaps your compiler can do something
  52. special.  Great.  As a designer of large systems I don't want to know
  53. about it.  They are just objects to which I can send messages, pass as
  54. parameters...  They have a protocol... and allow only those operations
  55. that are in line with their "essential sameness"
  56.  
  57. Are we talking about totally different things?
  58.  
  59. --
  60. --
  61. ato de, |m        -- Truth peels from the burning halls of words.
  62.