Debian Codegraph @

libstdc++-v3/testsuite/19_diagnostics/error_category/102425.cc

raw
1 // { dg-do run { target c++11 } }
2 #include <system_error>
3 #include <testsuite_hooks.h>
4
5 void test01()
6 {
7 // PR libstdc++/102425
8 VERIFY( std::error_code() == std::error_condition() );
9
10 auto zero = std::system_category().default_error_condition(0);
11 // This is the condition that the equality above relies on:
12 VERIFY( zero.category() == std::generic_category() );
13 }
14
15 int main()
16 {
17 test01();
18 }