home *** CD-ROM | disk | FTP | other *** search
/ Microsoftware Monthly 19…2 Programming Power Tools / MASO9512.ISO / cpptutor / cpptutor.arj / CH09 / A091421.TXT < prev    next >
Encoding:
Text File  |  1993-11-29  |  383 b   |  7 lines

  1. These lines are the declaration and definition of a nonstatic
  2. member function that overloads the unary minus operator for use
  3. with the Fraction class.  Notice that the function operator-()
  4. has no arguments.  An object of the Fraction class is passed
  5. through the "this" pointer.  The body of the function and the
  6. return value have the same form as in any user-defined function.
  7.