Modifiable typesafe variadic arguments

Deewiant deewiant.doesnotlike.spam at gmail.com
Thu Jun 15 04:50:34 PDT 2006


Daniel Keep wrote:
> Honestly, I think that when you ever pass something to a function that it can
> change, there should be some explicit notice of this (like having to pass the
> argument by address).

I agree. Hence I still hope for my suggestion (which was originally someone
else's idea, but I wrote it up at the D wish list,
http://all-technology.com/eigenpolls/dwishlist/ ) requesting usage of explicit
out/inout when calling to be implemented. Meaning, whenever you call a function
with out/inout arguments, you specify out/inout at the call point as well as at
the function definition.

> Well, ok, you could always play the "write a template for every possible
> argument length and use THAT to pass the arguments by address to the
> *real* function", but I think that's probably unnecessary :)
> 
> 	-- Daniel
> 

Of course, and I think that's unnecessary as well, not to mention somewhat
tedious. ;-)



More information about the Digitalmars-d-learn mailing list