On 10/12/20 2:11 AM, Dominikus Dittes Scherkl wrote:
> - Throw exceptions only if you have a plan what to do with them if you
> catch them.
My thinking is different: Throw exceptions if you can't accomplish a
task. My code is filled with enforce() and assert() checks, which do
throw
...
- ...no plan, better throw error...where and why the program
crashed...
Therefore a list of possible exceptions doesn't make any sense.
Thanks, Dominikus, those are great ideas.
your own.
- 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.
On Saturday, 10 October 2020 at 20:32:22 UTC, DMon wrote:
On Saturday, 10 October 2020 at 19:55:44 UTC, Ali Çehreli wrote:
On 10/10/20 12:51 PM, DMon wrote:
Thank you for your and Imperatorns time.
Even if it did go in circles and get stuck in the mud.
No problem. We're doing it out of
On Saturday, 10 October 2020 at 19:55:44 UTC, Ali Çehreli wrote:
On 10/10/20 12:51 PM, DMon wrote:
Thank you for your and Imperatorns time.
Even if it did go in circles and get stuck in the mud.
On 10/10/20 12:51 PM, DMon wrote:
> I will copy that down.
>
> The idea for specific exceptions came from the online docs and
> Programing in D, 39.2 The try-catch statemet
>
> try
> { // the code block that is being executed, where an // exception may be
> thrown
> }
> catch (an_exception_type)
On Saturday, 10 October 2020 at 18:16:45 UTC, Ali Çehreli wrote:
On 10/10/20 9:16 AM, DMon wrote:
> catch (Exception e) // implicit (any exception)
> catch (ConvException f) // explicit (conversion only)
>
> Or is that not correct?
I think in class hierarchies, "more general" and "more
On 10/10/20 9:16 AM, DMon wrote:
> catch (Exception e) // implicit (any exception)
> catch (ConvException f) // explicit (conversion only)
>
> Or is that not correct?
I think in class hierarchies, "more general" and "more specific" are
better terms. :)
The answer is, catch by the most
On Saturday, 10 October 2020 at 16:37:23 UTC, Imperatorn wrote:
On Saturday, 10 October 2020 at 12:12:35 UTC, DMon wrote:
To clarify, do you want a list of *possible* exceptions, like
in Java?
Please.
I've been looking and thinking that I'm over complicating it for
myself so it may
On Saturday, 10 October 2020 at 12:12:35 UTC, DMon wrote:
Is there a list of a list of the exceptions or what can be used
with catch?
I'm thinking that I missed it and there is something easier
than breaking old code, scouring the site, or hypnotic
regression.
To clarify, do you want
On Saturday, 10 October 2020 at 16:00:26 UTC, Ali Çehreli wrote:
On 10/10/20 8:46 AM, DMon wrote:
On Saturday, 10 October 2020 at 14:56:31 UTC, Ali Çehreli
wrote:
On 10/10/20 5:12 AM, DMon wrote:
Is there a list of a list of the exceptions or what can be
used with catch?
Only Throwable
On 10/10/20 8:46 AM, DMon wrote:
On Saturday, 10 October 2020 at 14:56:31 UTC, Ali Çehreli wrote:
On 10/10/20 5:12 AM, DMon wrote:
Is there a list of a list of the exceptions or what can be used with
catch?
Only Throwable and classes that are derived from it can be thrown and
caught.
Ali
On Saturday, 10 October 2020 at 14:56:31 UTC, Ali Çehreli wrote:
On 10/10/20 5:12 AM, DMon wrote:
Is there a list of a list of the exceptions or what can be
used with catch?
Only Throwable and classes that are derived from it can be
thrown and caught.
Ali
Thanks for the reply.
I am
On 10/10/20 5:12 AM, DMon wrote:
Is there a list of a list of the exceptions or what can be used with catch?
I'm thinking that I missed it and there is something easier than
breaking old code, scouring the site, or hypnotic regression.
Only Throwable and classes that are derived from it can
Is there a list of a list of the exceptions or what can be used
with catch?
I'm thinking that I missed it and there is something easier than
breaking old code, scouring the site, or hypnotic regression.
15 matches
Mail list logo