home *** CD-ROM | disk | FTP | other *** search
/ NetNews Usenet Archive 1992 #18 / NN_1992_18.iso / spool / comp / lang / c / 12449 < prev    next >
Encoding:
Internet Message Format  |  1992-08-17  |  2.3 KB

  1. Path: sparky!uunet!oracle!unrepliable!bounce
  2. Newsgroups: comp.lang.c
  3. From: wkaufman@us.oracle.com (William Kaufman)
  4. Subject: Re: Pointer/address reluctance
  5. Message-ID: <1992Aug15.150436.25713@oracle.us.oracle.com>
  6. Sender: usenet@oracle.us.oracle.com (Oracle News Poster)
  7. Nntp-Posting-Host: hqsun2.us.oracle.com
  8. Organization: Oracle Corporation, Redwood Shores CA
  9. References: <l8kteaINNp2c@exodus.Eng.Sun.COM> <1992Aug14.173255.10548@wyvern.twuug.com> <l8ojbqINN900@exodus.Eng.Sun.COM>
  10. Date: Sat, 15 Aug 1992 15:04:36 GMT
  11. X-Disclaimer: This message was written by an unauthenticated user
  12.               at Oracle Corporation.  The opinions expressed are those
  13.               of the user and not necessarily those of Oracle.
  14. Lines: 38
  15.  
  16. In article <l8ojbqINN900@exodus.Eng.Sun.COM> linden@positive.Eng.Sun.COM (Peter van der Linden) writes:
  17. ] I take the point that some folks like to distinguish 
  18. ] between pointers and addresses because of unusual hardware
  19. ] that may include capability or offset bits.  
  20. ] However, Joe put his finger on the nub of this by pointing
  21. ] out (heh!) that we may simply expand our informal concept 
  22.  
  23.     Well, let's say you've just bought the new Baron Samadi 2000
  24. computer, the first machine to run strictly on voodoo.  Since pointers
  25. are simply references to the original object,
  26.  
  27.         person *prez = George_Bush;
  28.  
  29. may be implemented as a voodoo doll of Bush.  And C should support such
  30. a machine.
  31.  
  32.         resign(prez);
  33.         prez = Dan_Quayle;
  34.  
  35.             Bus error,...world dumped.
  36.  
  37.     More seriously, the reason *I* avoid it is because there's always
  38. someone out there who thinks that all memory is byte addressable, and
  39. therefore, all pointers are integers representing a byte index into
  40. memory.  They come up with things like storing a pointer in an int, and
  41. using pointers to different types interchangeably.
  42.  
  43.     On a weekly basis, I see utter confusion pass over peoples' faces
  44. when I tell them, That's not true!  (It certainly happens here often
  45. enough,...)  It's just so much easier to imagine pointers as sheer
  46. magic, and treat them with the reverence they deserve.
  47.  
  48.                                            -- Bill K.
  49.  
  50. Bill Kaufman,          | "Hush my darling / Be still my darling /
  51. Corporate Lackey       |  The lion's on the phone,..."
  52. wkaufman@us.oracle.com |              -- "The Guitar", They Might Be Giants
  53.