]> git.ipfire.org Git - thirdparty/gcc.git/commitdiff
libstdc++: Do not use nullptr in C++03-compatible code
authorJonathan Wakely <jwakely@redhat.com>
Fri, 16 Sep 2022 13:27:43 +0000 (14:27 +0100)
committerJonathan Wakely <jwakely@redhat.com>
Fri, 16 Sep 2022 14:54:42 +0000 (15:54 +0100)
This has to be valid as C++98/C++03.

libstdc++-v3/ChangeLog:

* include/debug/formatter.h [_GLIBCXX_DEBUG_BACKTRACE]
(_Error_formatter): Use 0 as null pointer constant.

libstdc++-v3/include/debug/formatter.h

index b4b72383e222bc9ebccd62431c22c329e043504f..f120163c6d425f70cd128173066eaddf253f7d82 100644 (file)
@@ -609,8 +609,7 @@ namespace __gnu_debug
     , _M_function(__function)
 #if _GLIBCXX_HAVE_STACKTRACE
 # ifdef _GLIBCXX_DEBUG_BACKTRACE
-    , _M_backtrace_state(
-      __glibcxx_backtrace_create_state(nullptr, 0, nullptr, nullptr))
+    , _M_backtrace_state(__glibcxx_backtrace_create_state(0, 0, 0, 0))
     , _M_backtrace_full(&__glibcxx_backtrace_full)
 # else
     , _M_backtrace_state()