multiple opApply functions?

Bill Baxter dnewsgroup at
Tue May 22 04:01:54 PDT 2007

Jarrett Billingsley wrote:
> "Jason House" < at> wrote in message 
> news:f2tj95$2llq$1 at
>> Daniel Keep wrote:
>>> Just realised; if that version of gdc only implements D v1.007, you
>>> might need to try "inout" instead of "ref".
>> That worked, but now I'm confused... isn't inout the default way of 
>> passing parameters into functions?  I thought inout was assumed.
> No; inout is "by reference."  The default is in, which means "by value." 

But if you're passing a reference (a class instance or array) then "by 
value" means the pointer to the class or array is passed by value. 
Modifications to the contents are visible to the caller, modification of 
the pointer itself is not.


More information about the Digitalmars-d-learn mailing list