diff options
author | Jonathan Wakely <jwakely@redhat.com> | 2017-12-01 15:10:13 +0000 |
---|---|---|
committer | Jonathan Wakely <redi@gcc.gnu.org> | 2017-12-01 15:10:13 +0000 |
commit | c85d1992085c61f60c74d43a41619a83fba221b5 (patch) | |
tree | 86c2ccc69001a2f4e2aab1536b5073c800d5fb95 /libstdc++-v3 | |
parent | 071f228fa3aa83d24c465fe402732856c1246624 (diff) | |
download | gcc-c85d1992085c61f60c74d43a41619a83fba221b5.zip gcc-c85d1992085c61f60c74d43a41619a83fba221b5.tar.gz gcc-c85d1992085c61f60c74d43a41619a83fba221b5.tar.bz2 |
Add [[noreturn]] attributes to fix warning
* libsupc++/nested_exception.h (__throw_with_nested_impl): Add
noreturn attribute.
From-SVN: r255315
Diffstat (limited to 'libstdc++-v3')
-rw-r--r-- | libstdc++-v3/ChangeLog | 3 | ||||
-rw-r--r-- | libstdc++-v3/libsupc++/nested_exception.h | 2 |
2 files changed, 5 insertions, 0 deletions
diff --git a/libstdc++-v3/ChangeLog b/libstdc++-v3/ChangeLog index 1f138d7..4de8cc7 100644 --- a/libstdc++-v3/ChangeLog +++ b/libstdc++-v3/ChangeLog @@ -1,5 +1,8 @@ 2017-12-01 Jonathan Wakely <jwakely@redhat.com> + * libsupc++/nested_exception.h (__throw_with_nested_impl): Add + noreturn attribute. + * include/bits/regex_executor.tcc (_Executor::_M_rep_once_more): Remove semi-colon after function body. * include/bits/uniform_int_dist.h (_Power_of_2): Likewise. diff --git a/libstdc++-v3/libsupc++/nested_exception.h b/libstdc++-v3/libsupc++/nested_exception.h index 43970b4..27bccfc 100644 --- a/libstdc++-v3/libsupc++/nested_exception.h +++ b/libstdc++-v3/libsupc++/nested_exception.h @@ -92,6 +92,7 @@ namespace std // Throw an exception of unspecified type that is publicly derived from // both remove_reference_t<_Tp> and nested_exception. template<typename _Tp> + [[noreturn]] inline void __throw_with_nested_impl(_Tp&& __t, true_type) { @@ -100,6 +101,7 @@ namespace std } template<typename _Tp> + [[noreturn]] inline void __throw_with_nested_impl(_Tp&& __t, false_type) { throw std::forward<_Tp>(__t); } |