"Best" way of passing in a big struct to a function?

Don Clugston dac at nospam.com
Wed Oct 10 01:40:24 PDT 2012


On 10/10/12 09:12, thedeemon wrote:
> On Wednesday, 10 October 2012 at 07:28:55 UTC, Jonathan M Davis wrote:
>> Making sure that the aa has been properly initialized before passing
>> it to a function (which would mean giving it at least one value) would
>> make the ref completely unnecessary.
>>
>> - Jonathan M Davis
>
> Ah, thanks a lot! This behavior of a fresh AA being null and then
> silently converted to a non-null when being filled confused me.

Yes, it's confusing and annoying.
This is something in the language that we keep talking about fixing, but 
to date it hasn't happened.


More information about the Digitalmars-d-learn mailing list