On Sunday, 28 May 2017 at 19:10:49 UTC, ketmar wrote:
Meta wrote:
If a parameter is marked as ref then you have to assume it
will be modified by the function (unless it's
const/inout/immutable). If it's marked as out then you know it
will be. If you didn't know that the function takes its
parameters by ref or out... You're should've RTFM.
now imagine that you're reading some code:
foo(a);
vs:
foo(ref a);
which code style is easier to read without constant jumping
into documentation?
Is this ever actually a problem in practice?
Anyway, having to add ref or out at the call site will greatly
hamper metaprogramming.