summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorjsm28 <jsm28@138bc75d-0d04-0410-961f-82ee72b054a4>2000-10-17 07:00:06 +0000
committerjsm28 <jsm28@138bc75d-0d04-0410-961f-82ee72b054a4>2000-10-17 07:00:06 +0000
commit3f5c15cfbefb52dc16f677345013507bece5b01c (patch)
tree5c68b5ac8e40628ced4d113f5e849177158d9d78
parente37414d8f6a60088c7487b18eaedabb7086526a4 (diff)
downloadppe42-gcc-3f5c15cfbefb52dc16f677345013507bece5b01c.tar.gz
ppe42-gcc-3f5c15cfbefb52dc16f677345013507bece5b01c.zip
* decl.c (WINT_TYPE): Define.
(init_decl_processing): Create types unsigned_ptrdiff_type_node, c_size_type_node, signed_size_type_node and wint_type_node. git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@36898 138bc75d-0d04-0410-961f-82ee72b054a4
-rw-r--r--gcc/cp/ChangeLog6
-rw-r--r--gcc/cp/decl.c14
2 files changed, 18 insertions, 2 deletions
diff --git a/gcc/cp/ChangeLog b/gcc/cp/ChangeLog
index b9c74aded94..1c61ab2393c 100644
--- a/gcc/cp/ChangeLog
+++ b/gcc/cp/ChangeLog
@@ -1,5 +1,11 @@
2000-10-17 Joseph S. Myers <jsm28@cam.ac.uk>
+ * decl.c (WINT_TYPE): Define.
+ (init_decl_processing): Create types unsigned_ptrdiff_type_node,
+ c_size_type_node, signed_size_type_node and wint_type_node.
+
+2000-10-17 Joseph S. Myers <jsm28@cam.ac.uk>
+
* decl2.c (warn_missing_format_attribute): New variable.
(lang_decode_option): Decode -Wmissing-format-attribute.
diff --git a/gcc/cp/decl.c b/gcc/cp/decl.c
index ba99c3bd502..8e7443f09be 100644
--- a/gcc/cp/decl.c
+++ b/gcc/cp/decl.c
@@ -79,6 +79,10 @@ extern int (*valid_lang_attribute) PARAMS ((tree, tree, tree, tree));
#define WCHAR_TYPE "int"
#endif
+#ifndef WINT_TYPE
+#define WINT_TYPE "unsigned int"
+#endif
+
#ifndef INTMAX_TYPE
#define INTMAX_TYPE ((INT_TYPE_SIZE == LONG_LONG_TYPE_SIZE) \
? "int" \
@@ -6385,6 +6389,7 @@ init_decl_processing ()
ptrdiff_type_node
= TREE_TYPE (IDENTIFIER_GLOBAL_VALUE (get_identifier (PTRDIFF_TYPE)));
+ unsigned_ptrdiff_type_node = unsigned_type (ptrdiff_type_node);
/* Define both `signed char' and `unsigned char'. */
record_builtin_type (RID_MAX, "signed char", signed_char_type_node);
@@ -6393,8 +6398,10 @@ init_decl_processing ()
/* `unsigned long' is the standard type for sizeof.
Note that stddef.h uses `unsigned long',
and this must agree, even if long and int are the same size. */
- set_sizetype
- (TREE_TYPE (IDENTIFIER_GLOBAL_VALUE (get_identifier (SIZE_TYPE))));
+ c_size_type_node =
+ TREE_TYPE (IDENTIFIER_GLOBAL_VALUE (get_identifier (SIZE_TYPE)));
+ signed_size_type_node = signed_type (c_size_type_node);
+ set_sizetype (c_size_type_node);
/* Create the widest literal types. */
widest_integer_literal_type_node = make_signed_type (HOST_BITS_PER_WIDE_INT * 2);
@@ -6554,6 +6561,9 @@ init_decl_processing ()
wchar_array_type_node
= build_array_type (wchar_type_node, array_domain_type);
+ wint_type_node =
+ TREE_TYPE (IDENTIFIER_GLOBAL_VALUE (get_identifier (WINT_TYPE)));
+
intmax_type_node =
TREE_TYPE (IDENTIFIER_GLOBAL_VALUE (get_identifier (INTMAX_TYPE)));
uintmax_type_node =
OpenPOWER on IntegriCloud