'auto' keyword

Paul Backus snarwin at gmail.com
Sun Mar 12 15:59:54 UTC 2023


On Sunday, 12 March 2023 at 15:31:07 UTC, Salih Dincer wrote:
> Moreover, `auto ref` or `ref auto` is needed in functions.

That's because `ref` isn't part of the argument or return value's 
type, so it isn't covered by **type** inference. Instead, D has a 
totally separate feature for "`ref` inference".


More information about the Digitalmars-d-learn mailing list