home *** CD-ROM | disk | FTP | other *** search
/ NetNews Usenet Archive 1992 #26 / NN_1992_26.iso / spool / comp / lang / cplus / 15944 < prev    next >
Encoding:
Text File  |  1992-11-08  |  1.9 KB  |  87 lines

  1. Newsgroups: comp.lang.c++
  2. Path: sparky!uunet!elroy.jpl.nasa.gov!swrinde!zaphod.mps.ohio-state.edu!darwin.sura.net!spool.mu.edu!sol.ctr.columbia.edu!destroyer!fmsrl7!lynx!nmsu.edu!usenet
  3. From: willittl@spock.NMSU.Edu (William  Little)
  4. Subject: c++ & c+++
  5. Message-ID: <1992Nov8.222637.5773@nmsu.edu>
  6. Sender: usenet@nmsu.edu
  7. Organization: New Mexico State University
  8. Date: Sun, 8 Nov 1992 22:26:37 GMT
  9. Lines: 76
  10.  
  11.  
  12. Okay, a couple quick questions.
  13.  
  14. My employer recently bought Borland c++ compiler for
  15. windows and told me he bought some new C+++.  I personally
  16. have never heard of C+++.  Has anybody else?  Could he
  17. be confused about the Borland C++ 3 compiler for windows?
  18.  
  19. Now, on to my c++ questions.
  20.  
  21. In the past week I bought a couple books on c++ so I can 
  22. finally figure out what the difference is.  WOW!  I have
  23. been doing things the hard way!  But, I guess I will find
  24. out what it is worth when I start developing a windows
  25. application... ick.
  26.  
  27. The books I bought were for beginners, and didn't tell me 
  28. much.  I went through them in a couple hours, and came up
  29. with some questions in areas they didn't cover.
  30.  
  31. They made references to the functions and variables in 
  32. classes two different ways.
  33.  
  34. first:
  35.  
  36. class.variable
  37. class.function()
  38.  
  39. That was expected...
  40.  
  41. Then, they did this:
  42.  
  43. class::variable
  44. class::function()
  45.  
  46. Also, when they created a class such as:
  47.  
  48.  
  49.  
  50. class test   (simplistic flow - no flames please)
  51.   {
  52.   define variables....
  53.  
  54.   function1(){
  55.      code;
  56.      }
  57.  
  58.   function2(){
  59.      code;
  60.      }
  61.  
  62.   function3();
  63.   }   // end class
  64.  
  65. test::function3() {
  66.    code;
  67.    }
  68.  
  69. main() { did the goodies }
  70.  
  71. They created function3 inside the test class, yet defined
  72. the code for it out of the class definition, and used those
  73. nasty ::'s that confuse me so well.
  74.  
  75. What do the ::'s do??
  76.  
  77. The books I bought used them all over the place,  but never
  78. told me what they did.
  79.  
  80. Please help..  :)
  81.  
  82. Joseph Good
  83. (The sole user of a good friends donated unix account)
  84.  
  85. willittl@nmsu.edu
  86.  
  87.