This is the mail archive of the cygwin@sourceware.cygnus.com mailing list for the Cygwin project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]

Re: Newbie - exception handling


On Tue, 15 Dec 1998, Tim Hughes wrote:

> I have NT4 SP3,   egcs-1.1 and coolview.
> 
> I am writing v. simple  trial programs & I am not yet sure whether any of "try"  "catch" "throw" "except"  "finally"   (all possibly with single or double underscore prefixes) are implemented.
> 
> I have read stacks of mailing lists - could someone pls indicate a reference work, if any, to which the current implementations equate in terms of exception handling  (eg Stan Lippman's C++ Primer  edition 2 or edition 3)    ?

There is no "finally" and "except" in the C++ language, and hence neither
is implemented in GCC. There is only "throw" and "catch" and there are no 
underscores. If you want to use Microsoft's ad-hoc extensions, you need 
to use their compiler or implement it in GCC and contribute it to the FSF.

You should definitely get a recent book on C++ and possibly a book on 
STL if you're planning on writing any code in C++, and especially using
new'ish features that weren't there 4-5 years ago. I highly recommend the 
following combination as a good starting point:
  
  - C++ language and overview -- Bjarne Stroustrup 3rd edition
  - Standard Template Library -- Matthew Austern (Just out. An 
    excellent book for newbies and experts alike)

Stroustrup's book should give you pretty good idea of what C++ exception
handling is, what the keywords are, and how to use it.

Regards,
Mumit

ps: Please use an mail editor that (1) doesn't include HTML attachments, 
and (2) wraps long lines to <= 74 characters or so. The HTML crud is 
unnecessary, non-standard and downright annoying.


-
For help on using this list (especially unsubscribing), send a message to
"gnu-win32-request@cygnus.com" with one line of text: "help".


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]