Array as an argument, ambiguous behaviour.

Cooler kulkin at hotbox.ru
Thu Jan 30 06:18:40 PST 2014


Forgot to mention :)

>> I read the rest of the discussion. Arrays are hard to 
>> understand in D, especially if you have preconceived notions 
>> from other languages. But I would point out that fun2 does not 
>> "guarantee" anything more than fun3:
>>
>> void fun2(ref int [] x)
>> {
>>   fun3(x);
>> }
"But I would point out that fun2 does not guarantee anything more 
than fun3:" - fun2() cannot guarantee anything because it calls 
fun3() which in turn cannot guarantee anything.


More information about the Digitalmars-d-learn mailing list