what does this declaration mean? exception() throw()

后端 未结 5 1235
暗喜
暗喜 2021-01-12 05:34

std::exception class is defined as follows

exception() throw() { }
virtual ~exception() throw();
virtual const char* what() const throw();

5条回答
  •  难免孤独
    2021-01-12 06:02

    It's an exception specification. No arguments means that the function can't throw any exceptions.

提交回复
热议问题