summaryrefslogtreecommitdiff
path: root/gcc
diff options
context:
space:
mode:
authorrms <rms@138bc75d-0d04-0410-961f-82ee72b054a4>1992-07-17 04:15:55 +0000
committerrms <rms@138bc75d-0d04-0410-961f-82ee72b054a4>1992-07-17 04:15:55 +0000
commitf20853dd280477896071c835328860359b9573e0 (patch)
tree8c82feb6cda9f786b1122aa680ebc5983b16cc66 /gcc
parent6eaabe2ad71c691ec943c930e11361180cff1f7a (diff)
downloadgcc-f20853dd280477896071c835328860359b9573e0.tar.gz
(struct tree_block): New struct type definition added.
(BLOCK_VARS, BLOCK_TYPE_TAGS, BLOCK_SUBBLOCKS, BLOCK_HANDLER_BLOCK): Changed to reference fields of the new `struct tree_block' type. (BLOCK_ABSTRACT_ORIGIN, BLOCK_ABSTRACT): Definitions added. (union tree_node): Added `struct tree_block' as a new variant. git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@1602 138bc75d-0d04-0410-961f-82ee72b054a4
Diffstat (limited to 'gcc')
-rw-r--r--gcc/tree.h41
1 files changed, 29 insertions, 12 deletions
diff --git a/gcc/tree.h b/gcc/tree.h
index 01910ab33a2..d8dc82aeeb9 100644
--- a/gcc/tree.h
+++ b/gcc/tree.h
@@ -464,28 +464,44 @@ struct tree_vec
/* In a CONSTRUCTOR node. */
#define CONSTRUCTOR_ELTS(NODE) TREE_OPERAND (NODE, 1)
+/* In ordinary expression nodes. */
+#define TREE_OPERAND(NODE, I) ((NODE)->exp.operands[I])
+#define TREE_COMPLEXITY(NODE) ((NODE)->exp.complexity)
+
+struct tree_exp
+{
+ char common[sizeof (struct tree_common)];
+ int complexity;
+ union tree_node *operands[1];
+};
+
/* In a BLOCK node. */
-#define BLOCK_VARS(NODE) ((NODE)->exp.operands[0])
-#define BLOCK_TYPE_TAGS(NODE) ((NODE)->exp.operands[1])
-#define BLOCK_SUBBLOCKS(NODE) ((NODE)->exp.operands[2])
-#define BLOCK_SUPERCONTEXT(NODE) ((NODE)->exp.operands[3])
+#define BLOCK_VARS(NODE) ((NODE)->block.vars)
+#define BLOCK_TYPE_TAGS(NODE) ((NODE)->block.type_tags)
+#define BLOCK_SUBBLOCKS(NODE) ((NODE)->block.subblocks)
+#define BLOCK_SUPERCONTEXT(NODE) ((NODE)->block.supercontext)
/* Note: when changing this, make sure to find the places
that use chainon or nreverse. */
#define BLOCK_CHAIN(NODE) TREE_CHAIN (NODE)
+#define BLOCK_ABSTRACT_ORIGIN(NODE) ((NODE)->block.abstract_origin)
+#define BLOCK_ABSTRACT(NODE) ((NODE)->block.abstract_flag)
/* Nonzero means that this block is prepared to handle exceptions
listed in the BLOCK_VARS slot. */
-#define BLOCK_HANDLER_BLOCK(NODE) TREE_PROTECTED(NODE)
+#define BLOCK_HANDLER_BLOCK(NODE) ((NODE)->block.handler_block_flag)
-/* In ordinary expression nodes. */
-#define TREE_OPERAND(NODE, I) ((NODE)->exp.operands[I])
-#define TREE_COMPLEXITY(NODE) ((NODE)->exp.complexity)
-
-struct tree_exp
+struct tree_block
{
char common[sizeof (struct tree_common)];
- int complexity;
- union tree_node *operands[1];
+
+ unsigned handler_block_flag : 1;
+ unsigned abstract_flag : 1;
+
+ union tree_node *vars;
+ union tree_node *type_tags;
+ union tree_node *subblocks;
+ union tree_node *supercontext;
+ union tree_node *abstract_origin;
};
/* Define fields and accessors for nodes representing data types. */
@@ -898,6 +914,7 @@ union tree_node
struct tree_list list;
struct tree_vec vec;
struct tree_exp exp;
+ struct tree_block block;
};
/* Format for global names of constructor and destructor functions. */