Fix build on gcc < 5 (std::is_trivially_copyable missing)
[deliverable/binutils-gdb.git] / gdb / common / common-defs.h
index 3d5ff188278a5b0de86c7c280f083809502a6ba7..439bce622f6b7bfbc9e3b95c5f275fa9290f44dd 100644 (file)
@@ -1,6 +1,6 @@
 /* Common definitions.
 
-   Copyright (C) 1986-2016 Free Software Foundation, Inc.
+   Copyright (C) 1986-2017 Free Software Foundation, Inc.
 
    This file is part of GDB.
 
    macros such as INTMAX_C, and one must define __STDC_LIMIT_MACROS to
    make visible the definitions of limit macros such as INTMAX_MAX.".
 
-   Must do this before including any system header, since system
-   headers may include stdint.h.  */
+   And:
+    https://www.gnu.org/software/gnulib/manual/html_node/inttypes_002eh.html
+
+   "On some hosts that predate C++11, when using C++ one must define
+   __STDC_FORMAT_MACROS to make visible the declarations of format
+   macros such as PRIdMAX."
+
+   Must do this before including any system header, since other system
+   headers may include stdint.h/inttypes.h.  */
 #define __STDC_CONSTANT_MACROS 1
 #define __STDC_LIMIT_MACROS 1
+#define __STDC_FORMAT_MACROS 1
 
 #include <stdarg.h>
 #include <stdio.h>
 #include "common-debug.h"
 #include "cleanups.h"
 #include "common-exceptions.h"
+#include "common/poison.h"
 
 #define EXTERN_C extern "C"
 #define EXTERN_C_PUSH extern "C" {
 #define EXTERN_C_POP }
 
-/* Pull in gdb::unique_ptr and gdb::unique_xmalloc_ptr.  */
+/* Pull in gdb::unique_xmalloc_ptr.  */
 #include "common/gdb_unique_ptr.h"
 
 #endif /* COMMON_DEFS_H */
This page took 0.024547 seconds and 4 git commands to generate.