gcc/libstdc++-v3/doc
Jonathan Wakely 361d230fd7
libstdc++: Enable _GLIBCXX_ASSERTIONS by default for -O0 [PR112808]
Too many users don't know about -D_GLIBCXX_ASSERTIONS and so are missing
valuable checks for C++ standard library preconditions. This change
enables libstdc++ assertions by default when compiling with -O0 so that
we diagnose more bugs by default.

When users enable optimization we don't add the assertions by default
(because they have non-zero overhead) so they still need to enable them
manually.

For users who really don't want the assertions even in unoptimized
builds, defining _GLIBCXX_NO_ASSERTIONS will prevent them from being
enabled automatically.

libstdc++-v3/ChangeLog:

	PR libstdc++/112808
	* doc/xml/manual/using.xml (_GLIBCXX_ASSERTIONS): Document
	implicit definition for -O0 compilation.
	(_GLIBCXX_NO_ASSERTIONS): Document.
	* doc/html/manual/using_macros.html: Regenerate.
	* include/bits/c++config [!__OPTIMIZE__] (_GLIBCXX_ASSERTIONS):
	Define for unoptimized builds.
2024-10-09 13:39:16 +01:00
..
doxygen libstdc++: Simplify std::aligned_storage and fix for versioned namespace [PR61458] 2024-10-09 13:39:16 +01:00
html libstdc++: Enable _GLIBCXX_ASSERTIONS by default for -O0 [PR112808] 2024-10-09 13:39:16 +01:00
xml libstdc++: Enable _GLIBCXX_ASSERTIONS by default for -O0 [PR112808] 2024-10-09 13:39:16 +01:00
xsl
Makefile.am Update copyright years. 2024-01-03 12:19:35 +01:00
Makefile.in libstdc++: Fix 'doc-install-info' rule 2023-09-07 17:50:46 +01:00