FeedbackThread: DIP 1038-- at nodiscard--Community Review Round 1

Jacob Carlborg doob at me.com
Fri Dec 11 20:01:38 UTC 2020


On 2020-12-09 11:11, Mike Parker wrote:
> This is the feedback thread for the first round of Community Review of 
> DIP 1038, "@nodiscard".

The DIP doesn't mention anything about constructors. It should mention 
if this attribute can be applied to constructors. It should also mention 
if it applies to if the attribute is attached to the type and a 
constructor is called for that type.

For constructors, there is mostly no other option of error handling than 
exceptions. Perhaps an `out` parameter could work.

-- 
/Jacob Carlborg


More information about the Digitalmars-d mailing list