List of exceptions?
Dominikus Dittes Scherkl
dominikus at scherkl.de
Mon Oct 12 09:11:35 UTC 2020
On Saturday, 10 October 2020 at 19:51:10 UTC, DMon wrote:
> This is where I'm at:
> import std.stdio;
> import std.conv;
> // StdioException
> // ConvException
> // StringException
> // ErrnoException
> // FormatException
> // UnicodeException
> // UTFException
> // FileMissingException
> // DataCorruptionException
> // FE_INEXACT
> // FE_UNDERFLOW
> // FE_OVERFLOW
- You should not care about exceptions someone else defined in
his library (maybe except for printing out their message in
main(), for which you don't need to know the exact type).
- You should not reuse exceptions defined by someone else. Define
- Throw exceptions only if you have a plan what to do with them
if you catch them.
- If you have no plan, better throw error, just to get an idea
where and why the program crashed (and don't try to catch them)
Therefore a list of possible exceptions doesn't make any sense.
More information about the Digitalmars-d-learn