llvm-project
llvm-project copied to clipboard
no warning for unused std::error_code
#include <system_error>
void foo()
{
std::error_code ec;
}
The code does get optimized away as system_category() is [[gnu::const]] but there is no -Wunused warning.
https://godbolt.org/z/M68ToY78b