gengtype.c (main): Make uintptr_t a known type.
authorTristan Gingold <gingold@adacore.com>
Tue, 10 Apr 2012 08:32:23 +0000 (08:32 +0000)
committerTristan Gingold <gingold@gcc.gnu.org>
Tue, 10 Apr 2012 08:32:23 +0000 (08:32 +0000)
gcc/
2012-04-10  Tristan Gingold  <gingold@adacore.com>

* gengtype.c (main): Make uintptr_t a known type.

include/
2012-04-10  Tristan Gingold  <gingold@adacore.com>

* splay-tree.h: Conditionnaly includes stdint.h and inttypes.h
(libi_uhostptr_t, libi_shostptr_t): Remove, replaced by uintptr_t.

From-SVN: r186269

gcc/ChangeLog
gcc/gengtype.c
include/ChangeLog
include/splay-tree.h

index 3a1819dfff3d822cc8b583e7f7ff8ea41d7db7d5..2e39f782f6019a2f47341add3c2561be6e1f1d2a 100644 (file)
@@ -1,3 +1,7 @@
+2012-04-10  Tristan Gingold  <gingold@adacore.com>
+
+       * gengtype.c (main): Make uintptr_t a known type.
+
 2012-04-10  Richard Guenther  <rguenther@suse.de>
 
        * tree-pass.h (tree_lowering_passes): Remove.
index 7450eebac4f919b900e863549772e512d7afabc0..fa4539298148f437ecad42987884befac42c2235 100644 (file)
@@ -4976,6 +4976,7 @@ main (int argc, char **argv)
       POS_HERE (do_scalar_typedef ("double_int", &pos));
       POS_HERE (do_scalar_typedef ("uint64_t", &pos));
       POS_HERE (do_scalar_typedef ("uint8", &pos));
+      POS_HERE (do_scalar_typedef ("uintptr_t", &pos));
       POS_HERE (do_scalar_typedef ("jword", &pos));
       POS_HERE (do_scalar_typedef ("JCF_u2", &pos));
       POS_HERE (do_scalar_typedef ("void", &pos));
index b9e81e31f407e0475f84a49ce2c0510393e73dd9..4e0ee9a0c1ca8c4226c30a992c9b874ded03626b 100644 (file)
@@ -1,3 +1,8 @@
+2012-04-10  Tristan Gingold  <gingold@adacore.com>
+
+       * splay-tree.h: Conditionnaly includes stdint.h and inttypes.h
+       (libi_uhostptr_t, libi_shostptr_t): Remove, replaced by uintptr_t.
+
 2012-01-26  Cary Coutant  <ccoutant@google.com>
 
        * dwarf2.h (enum dwarf_form): Add Fission extensions.
index 480b2c43e7d4d654e971ce77a6ac67dc860ebfcc..a26135a099de4e672856385640ccce1fbb8aeb2d 100644 (file)
@@ -37,18 +37,11 @@ extern "C" {
 
 #include "ansidecl.h"
 
-#ifndef _WIN64
-  typedef unsigned long int libi_uhostptr_t;
-  typedef long int libi_shostptr_t;
-#else
-#ifdef __GNUC__
-  __extension__
+#ifdef HAVE_STDINT_H
+#include <stdint.h>
 #endif
-  typedef unsigned long long libi_uhostptr_t;
-#ifdef __GNUC__
-  __extension__
-#endif
-  typedef long long libi_shostptr_t;
+#ifdef HAVE_INTTYPES_H
+#include <inttypes.h>
 #endif
 
 #ifndef GTY
@@ -59,8 +52,8 @@ extern "C" {
    these types, if necessary.  These types should be sufficiently wide
    that any pointer or scalar can be cast to these types, and then
    cast back, without loss of precision.  */
-typedef libi_uhostptr_t splay_tree_key;
-typedef libi_uhostptr_t splay_tree_value;
+typedef uintptr_t splay_tree_key;
+typedef uintptr_t splay_tree_value;
 
 /* Forward declaration for a node in the tree.  */
 typedef struct splay_tree_node_s *splay_tree_node;