home *** CD-ROM | disk | FTP | other *** search
/ Microsoftware Monthly 19…2 Programming Power Tools / MASO9512.ISO / cpptutor / cpptutor.arj / CH16 / A16342.TXT < prev    next >
Encoding:
Text File  |  1993-11-25  |  394 b   |  8 lines

  1. In this example, Exception is a base exception class from which
  2. the class MathExcept is derived.  Notice that the exception
  3. specification of the function divide() lets it throw only
  4. exceptions of type Exception and that the handler in main()
  5. catches only exceptions of type Exception.  Since a MathExcept
  6. object is an Exception object, the MathExcept exception can be
  7. thrown and caught.
  8.