DIP 1038--"@mustUse" (formerly "@noDiscard")--Accepted
forkit
forkit at gmail.com
Tue Feb 8 03:48:22 UTC 2022
On Tuesday, 8 February 2022 at 02:57:29 UTC, forkit wrote:
>
> I would prefer @must_use over @mustUse, for example (althouhgh
> i prefer @mustuse to both of these, since the underscore is not
> really needed in this case).
>
my argument for the above, is:
The problem with using camelCase on @attributes, is that it
implies nothing special about it (the attribute), at all.
It is common practice to use camelCase for things like variables,
function names, etc... i.e. things that hold something, or do
something.
Whereas an @attribute is essentially a predicate.
You are proclaiming a static declaration, that will apply to what
follows.
As such, it deserves to stand out, with a different naming
convention.
That is: all @lowercase, but when required, @snake_case.
More information about the Digitalmars-d-announce
mailing list