2 days ago

On Thursday, 3 October 2024 at 14:27:37 UTC, Imperatorn wrote:

>

On Wednesday, 2 October 2024 at 18:57:24 UTC, Timon Gehr wrote:

>

On 10/2/24 20:00, Walter Bright wrote:

>

[...]

I don't think it affects how overloading works. You just treat it as a by-value argument as far as overloading and lifetime handling is concerned. In terms of ABI however, you pass the argument by reference.

[...]

What is the amount we need to pay to not get another attribute?

This probably wouldn't be a language attribute like @nogc or @trusted. It would be a simple UDA that is defined as a compiler intrinsic. It would likely be defined either at core.attribute, or somewhere at core.internal.

And in any case it wouldn't be anything the D programmer has to deal with. It'd be used to define DRuntime functions, and maybe some low-level Phobos / utility library functions. But not at application code, nor even at normal library code.

1 2 3 4 5 6 7
Next ›   Last »