cplusplus / draft

C++ standards drafts
http://www.open-std.org/jtc1/sc22/wg21/
5.69k stars 750 forks source link

[containers] "throws an exception" #3207

Open FrankHB opened 5 years ago

FrankHB commented 5 years ago

Should subclauses in [containers] follow the resolution of LWG 1004?

Further, when do we really need "throws an exception" (if any)?

jensmaurer commented 5 years ago

@zygoloid, is this editorial given LWG 1004?

jwakely commented 5 years ago

It might be better to just add blanket wording to say that when we say a library function throws an exception we are talking about some part of the function throwing or propagating one, and the function not swallowing it.

jensmaurer commented 5 years ago

@jwakely, why? If we agree that we mean "exits via an exception", we should use these words throughout instead of using other words that might say something we don't mean.

jwakely commented 5 years ago

OK, it's just more work to do that, and personally I don't see a large benefit. But some other people in LWG do get upset by the inaccuracy of the current wording.

jensmaurer commented 5 years ago

Editorial teleconference: Go with "exits via an exception" wherever we say "throws an exception" and we mean the former.

jensmaurer commented 5 years ago

It's not obvious how to concisely phrase "Throws: Any exception thrown by <blah>."

(Branch c25.)

jensmaurer commented 5 years ago

Editorial teleconference: Just fix the simple cases and punt the rest to LWG.