DMD 1.027 and 2.011 releases

Walter Bright newshound1 at digitalmars.com
Mon Feb 25 01:44:15 PST 2008


Ary Borenszweig wrote:
> Does this mean this will not compile:
> 
> int foo(int[] someArray, int someIndex) nothrow {
>     return someArray[someIndex];
> }
> 
> but this will:
> 
> int foo(int[] someArray, int someIndex) nothrow {
>     if (someIndex < someArray.length) {
>         return someArray[someIndex];
>     } else {
>         return -1;
>     }
> }

I don't know yet. But the idea is to do static checking of what can throw.


More information about the Digitalmars-d-announce mailing list