You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
This repository was archived by the owner on Jan 30, 2026. It is now read-only.
Compile dies upon include. Here are the clang++ results:
./upptest.h:97:15: error: exception specification of overriding function is more lax than base version
const char* what() const override { return _msg.c_str(); }
^
/usr/bin/../lib/gcc/x86_64-linux-gnu/9/../../../../include/c++/9/bits/exception.h:75:5: note: overridden virtual function is here
what() const _GLIBCXX_TXN_SAFE_DYN _GLIBCXX_NOTHROW;
^
1 error generated.
g++ results:
In file included from play.cpp:5:
upptest.h:97:15: error: looser throw specifier for ‘virtual const char* utest::assert_fail_exception::what() const’
97 | const char* what() const override { return _msg.c_str(); }
| ^~~~
In file included from /usr/include/c++/9/exception:38,
from upptest.h:51,
from play.cpp:5:
/usr/include/c++/9/bits/exception.h:75:5: note: overridden function is ‘virtual const char* std::exception::what() const noexcept’
75 | what() const _GLIBCXX_TXN_SAFE_DYN _GLIBCXX_NOTHROW;
| ^~~~
In file included from play.cpp:5:
upptest.h:146:15: error: declaration of ‘const utest::info* utest::result::info’ changes meaning of ‘info’ [-fpermissive]
146 | const info* info;
| ^~~~
upptest.h:114:8: note: ‘info’ declared here as ‘class utest::info’
114 | class info;
| ^~~~
upptest.h:147:10: error: declaration of ‘utest::status utest::result::status’ changes meaning of ‘status’ [-fpermissive]
147 | status status;
| ^~~~~~
upptest.h:107:13: note: ‘status’ declared here as ‘enum class utest::status’
107 | enum class status
| ^~~~~~
The errors are the same for -std=c++11 with more that follow.
Compile dies upon include. Here are the clang++ results:
g++ results:
The errors are the same for -std=c++11 with more that follow.
Cheers,
Joe