throws Exception in method
amehat via Digitalmars-d-learn
digitalmars-d-learn at puremagic.com
Thu May 8 08:19:04 PDT 2014
On Thursday, 8 May 2014 at 14:02:06 UTC, monarch_dodra wrote:
> On Thursday, 8 May 2014 at 13:06:05 UTC, amehat wrote:
>> Okay.
>> Thank you for these explanations, I understand a little better
>> the exceptions D.
>
> Keep in mind that D also has the concept of "Error". Both
> "Exception" and "Error" derive from "Throwable".
>
> "nothrow" only means the function will not throw an *Exception*.
>
> "Error" can be thrown any time, from anywhere. They bypass the
> nothrow, bypass destructor cleanup, and fly past "catch
> (Exception)".
>
> An Error is basically: "A critical Error has occurred. Salvage
> what you can before dying."
I do not know the mistakes, at least not as you speak. I just
read on http://dlang.org/errors.html errors.
You mean errors and exceptions are almost identical?
More information about the Digitalmars-d-learn
mailing list