digitalmars.D.bugs - [Issue 20165] New: Add standard nodiscard attribute for functions
- d-bugmail puremagic.com (20/20) Aug 24 2019 https://issues.dlang.org/show_bug.cgi?id=20165
https://issues.dlang.org/show_bug.cgi?id=20165 Issue ID: 20165 Summary: Add standard nodiscard attribute for functions Product: D Version: D2 Hardware: All OS: All Status: NEW Severity: enhancement Priority: P1 Component: dmd Assignee: nobody puremagic.com Reporter: turkeyman gmail.com Can we please have a standard nodiscard attribute that all implementations agree on? Do want compile errors when functions discard the result form nodiscard functions. It can help reduce bugs in some cases, and it's a very nice self-documenting feature which makes the API intent a little clearer. --
Aug 24 2019