Thread overview | ||||||
---|---|---|---|---|---|---|
|
July 20, 2009 void myMethod() throw() | ||||
---|---|---|---|---|
| ||||
Does D2 has the equivalent implemenation of exception no throw out of a method: void myMethod() throw(){} Or,D2 has its own/better implementation on such feature,if yes,what is that? Thanks in advance. Regards, Sam |
July 20, 2009 Re: void myMethod() throw() | ||||
---|---|---|---|---|
| ||||
Posted in reply to Sam Hu | Sam Hu wrote:
> Does D2 has the equivalent implemenation of exception no throw out of a method:
>
> void myMethod() throw(){}
>
> Or,D2 has its own/better implementation on such feature,if yes,what is that?
>
> Thanks in advance.
> Regards,
> Sam
Yes, it's called nothrow. :)
nothrow void myMethod() { ... }
-Lars
|
July 21, 2009 Re: void myMethod() throw() | ||||
---|---|---|---|---|
| ||||
Posted in reply to Lars T. Kyllingstad | Lars T. Kyllingstad Wrote:
>
> Yes, it's called nothrow. :)
>
> nothrow void myMethod() { ... }
>
> -Lars
Thanks a lot.I have tried to search in section Expression,Statment,Classes ,Handling Errors of D2 spec but no found...
|
July 21, 2009 Re: void myMethod() throw() | ||||
---|---|---|---|---|
| ||||
Posted in reply to Sam Hu | Sam Hu wrote: > Lars T. Kyllingstad Wrote: >> Yes, it's called nothrow. :) >> >> nothrow void myMethod() { ... } >> >> -Lars > > Thanks a lot.I have tried to search in section Expression,Statment,Classes ,Handling Errors of D2 spec but no found... It's located under "Functions": http://www.digitalmars.com/d/2.0/function.html#nothrow-functions -Lars |
Copyright © 1999-2021 by the D Language Foundation