We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
[[nodiscard]]
1 parent 62da4f5 commit 7abbca1Copy full SHA for 7abbca1
docs/error-messages/compiler-warnings/c4834.md
@@ -43,7 +43,7 @@ int square_of(int i) { return i * i; }
43
int main()
44
{
45
square_of(42); // warning C4834: discarding return value of function with 'nodiscard' attribute
46
- // If ignoring the [[nodiscard] attribute is unintentional, make use of the return value as intended:
+ // If ignoring the [[nodiscard]] attribute is unintentional, make use of the return value as intended:
47
// For example:
48
std::cout << "square_of(42) = " << square_of(42) << "\n"; // Ok
49
// Or:
0 commit comments