Replace the last instance of throw() with noexcept. NFC.

Fixes a -Wdeprecated warning.

/home/travis/build/Quuxplusone/googletest/googletest/test/googletest-death-test_ex_test.cc:62:28: error:
      dynamic exception specifications are deprecated [-Werror,-Wdeprecated]
  const char* what() const throw() override { return "exceptional message"; }
                           ^~~~~~~
/home/travis/build/Quuxplusone/googletest/googletest/test/googletest-death-test_ex_test.cc:62:28: note:
      use 'noexcept' instead
  const char* what() const throw() override { return "exceptional message"; }
                           ^~~~~~~
                           noexcept
This commit is contained in:
Arthur O'Dwyer 2020-03-28 14:27:18 -04:00
parent 67cc66080d
commit 6ed4e7168f

View File

@ -59,7 +59,7 @@ TEST(CxxExceptionDeathTest, ExceptionIsFailure) {
class TestException : public std::exception {
public:
const char* what() const throw() override { return "exceptional message"; }
const char* what() const noexcept override { return "exceptional message"; }
};
TEST(CxxExceptionDeathTest, PrintsMessageForStdExceptions) {