On Sunday, 27 April 2014 at 08:04:54 UTC, Andrej Mitrovic via Digitalmars-d-learn wrote:
On 4/27/14, Damian Day via Digitalmars-d-learn
<[email protected]> wrote:
So I have this procedure.

Have a look at std.exception.assumeWontThrow:
http://dlang.org/phobos/std_exception.html#.assumeWontThrow

Keep in mind that "assume won't throw" will assert *should* an exception actually be thrown.

If the function actually can and will throw, but you simply don't care, you'd need a "squelchException" (which we don't have), or more simply, just:
//----
try {
    myCode();
} catch (Exception){}
//----

Reply via email to