Subclass of Exception

bearophile via Digitalmars-d-learn digitalmars-d-learn at puremagic.com
Sat Jun 14 05:19:56 PDT 2014


Paul:

>   class MyError : Exception {
>     this(string msg) { super(msg); }
>   }

Don't call exceptions errors, because in D there are also errors, 
so they should have distinct names.


> Is any shorter D way?

Perhaps not.

Bye,
bearophile


More information about the Digitalmars-d-learn mailing list