• Home
  • Line#
  • Scopes#
  • Navigate#
  • Raw
  • Download
1+++
2title = "`BOOST_OUTCOME_NODISCARD`"
3description = "How to tell the compiler than the return value of a function should not be discarded without examining it."
4+++
5
6Compiler-specific markup used to tell the compiler than the return value of a function should not be discarded without examining it.
7
8*Overridable*: Define before inclusion.
9
10*Default*: To `[[nodiscard]]` if on C++ 17 or higher, `__attribute__((warn_unused_result))` if on clang, SAL `_Must_inspect_result_` if on MSVC, otherwise nothing.
11
12*Header*: `<boost/outcome/config.hpp>`