Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

How do I know the exact exception type?

We use CDynamicAccessor which inherits from CAccessorBase. The function MoveNext would throw

HRESULT MoveNext() throw()

but without telling what exception type it is. How do I know it?

like image 814
Zhang Avatar asked Mar 15 '26 19:03

Zhang


1 Answers

No, throw() means the function is declared not to throw any exceptions.

Note that it's deprecated (and removed in C++20); we can use noexcept (or noexcept(true)) since C++11.

like image 64
songyuanyao Avatar answered Mar 18 '26 10:03

songyuanyao



Donate For Us

If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!