zeux / pugixml

Light-weight, simple and fast XML parser for C++ with XPath support
http://pugixml.org/
MIT License
4.01k stars 728 forks source link

throw() -> noexcept #623

Closed r-barnes closed 2 weeks ago

r-barnes commented 3 months ago

throw() was deprecated in C++11 and removed in C++17. noexcept is the appropriate fix.

zeux commented 3 months ago

Only deprecated in 17 and removed in 20 according to https://en.cppreference.com/w/cpp/language/noexcept_spec. pugixml doesn’t require C++11 so this will need to be guarded appropriately.

r-barnes commented 3 months ago

@zeux - ironically the same site shows C++11/C++17 here, but what you've found matches my experience: https://en.cppreference.com/w/cpp/language/except_spec

I've used the gated form.

zeux commented 3 months ago

ironically the same site shows C++11/C++17 here

That’s referring to a non-empty throw specification which had a different deprecation schedule.

zeux commented 3 months ago

PUGIXML_NOEXCEPT should be defined as throw() for builds to pass I believe.