C++ Logo

std-discussion

Advanced search

What is the difference between "Throws: Nothing." and noexcept(true)

From: Peter Sommerlad (C++) <"Peter>
Date: Wed, 15 Jul 2020 11:18:34 +0200
Hi,

while looking at <charconv> I was wondering why the from_chars() and
to_chars() are not noexcept. I understand that noexcept might lead to
worse code generation because of std::terminate() might need to be called.

Is that the sole reason for not making those functions noexcept(true) ?

TIA & Stay Healthy & Regards
Peter.
-- 
Peter Sommerlad
Better Software: Consulting, Training, Reviews
Modern, Safe & Agile C++
peter.cpp_at_[hidden]
+41 79 432 23 32

Received on 2020-07-15 04:21:55