diff options
author | David Malcolm <dmalcolm@redhat.com> | 2017-11-29 22:07:32 +0000 |
---|---|---|
committer | David Malcolm <dmalcolm@gcc.gnu.org> | 2017-11-29 22:07:32 +0000 |
commit | 591996bad79b7b109bb01fba69b1c7acc054e287 (patch) | |
tree | 403022637b8440b706dd47ce33c9f34f8c21a943 /libstdc++-v3 | |
parent | cc6fe784486b77d96bd4cb9cb1d6556c1d5480fb (diff) | |
download | gcc-591996bad79b7b109bb01fba69b1c7acc054e287.zip gcc-591996bad79b7b109bb01fba69b1c7acc054e287.tar.gz gcc-591996bad79b7b109bb01fba69b1c7acc054e287.tar.bz2 |
C++: improve location of static_assert errors
gcc/cp/ChangeLog:
* parser.c (cp_parser_unary_expression): Generate a location for
"noexcept".
(cp_parser_trait_expr): Generate and return a location_t,
converting the return type from tree to cp_expr.
(cp_parser_static_assert): Pass location of the condition to
finish_static_assert, rather than that of the "static_assert"
token, where available.
gcc/testsuite/ChangeLog:
* g++.dg/cpp1y/static_assert3.C: New test case.
libstdc++-v3/ChangeLog:
* testsuite/20_util/duration/literals/range.cc: Update expected
line of a static_assert failure.
From-SVN: r255255
Diffstat (limited to 'libstdc++-v3')
-rw-r--r-- | libstdc++-v3/ChangeLog | 5 | ||||
-rw-r--r-- | libstdc++-v3/testsuite/20_util/duration/literals/range.cc | 2 |
2 files changed, 6 insertions, 1 deletions
diff --git a/libstdc++-v3/ChangeLog b/libstdc++-v3/ChangeLog index aa764f5..a82f464 100644 --- a/libstdc++-v3/ChangeLog +++ b/libstdc++-v3/ChangeLog @@ -1,3 +1,8 @@ +2017-11-29 David Malcolm <dmalcolm@redhat.com> + + * testsuite/20_util/duration/literals/range.cc: Update expected + line of a static_assert failure. + 2017-11-28 Glen Joseph Fernandes <glenjofe@gmail.com> * include/bits/ptr_traits.h (to_address): Implement to_address. diff --git a/libstdc++-v3/testsuite/20_util/duration/literals/range.cc b/libstdc++-v3/testsuite/20_util/duration/literals/range.cc index 36e71ee..c0d1a6e 100644 --- a/libstdc++-v3/testsuite/20_util/duration/literals/range.cc +++ b/libstdc++-v3/testsuite/20_util/duration/literals/range.cc @@ -26,6 +26,6 @@ test01() // std::numeric_limits<int64_t>::max() == 9223372036854775807; auto h = 9223372036854775808h; - // { dg-error "cannot be represented" "" { target *-*-* } 891 } + // { dg-error "cannot be represented" "" { target *-*-* } 892 } } // { dg-prune-output "in constexpr expansion" } // needed for -O0 |