https://gcc.gnu.org/bugzilla/show_bug.cgi?id=86821
Bug ID: 86821 Summary: std::system_category() should map EDEADLOCK to EDEADLK Product: gcc Version: 9.0 Status: UNCONFIRMED Severity: enhancement Priority: P3 Component: libstdc++ Assignee: unassigned at gcc dot gnu.org Reporter: redi at gcc dot gnu.org Target Milestone: --- As of r263210 this passes on x86_64-pc-linux-gnu but fails on powerpc64le-unknown-linux-gnu and fails on newlib targets: #include <system_error> #include <cassert> #include <cerrno> int main() { std::error_condition errcond(std::errc::resource_deadlock_would_occur); #ifdef EDEADLOCK assert( std::system_category().equivalent(EDEADLOCK, errcond) ); #endif } It would be nice if it passed consistently, i.e. if EDEADLOCK corresponded to EDEADLK for the "system" error category.