Returning dynamic array from the function
sclytrack
sclytrack at sleepy.com
Wed Oct 17 13:15:19 PDT 2012
On Wednesday, 17 October 2012 at 19:46:51 UTC, bearophile wrote:
> sclytrack:
>
>> It doesn't give an error when marking the function with safe.
>>
>> @safe
>> int[] create()
>> {
>> }
>
> I think marking it @safe is not relevant. In theory a good type
> system should give an error message on similar code. I don't
> know if D is supposed to spot similar error situations.
>
> Bye,
> bearophile
If that's the case then they should call it safeR D instead of
safe D.
More information about the Digitalmars-d-learn
mailing list