projects
/
platform
/
upstream
/
gcc.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
a9d07d6
)
(get_unwidened): Don't crash if FIELD_DECL not layed out.
author
Richard Kenner
<kenner@gcc.gnu.org>
Sat, 18 Jan 1997 20:58:48 +0000
(15:58 -0500)
committer
Richard Kenner
<kenner@gcc.gnu.org>
Sat, 18 Jan 1997 20:58:48 +0000
(15:58 -0500)
From-SVN: r13508
gcc/tree.c
patch
|
blob
|
history
diff --git
a/gcc/tree.c
b/gcc/tree.c
index
f8b1a6e
..
d9b5abe
100644
(file)
--- a/
gcc/tree.c
+++ b/
gcc/tree.c
@@
-4181,7
+4181,9
@@
get_unwidened (op, for_type)
if (TREE_CODE (op) == COMPONENT_REF
/* Since type_for_size always gives an integer type. */
- && TREE_CODE (type) != REAL_TYPE)
+ && TREE_CODE (type) != REAL_TYPE
+ /* Don't crash if field not layed out yet. */
+ && DECL_SIZE (TREE_OPERAND (op, 1)) != 0)
{
unsigned innerprec = TREE_INT_CST_LOW (DECL_SIZE (TREE_OPERAND (op, 1)));
type = type_for_size (innerprec, TREE_UNSIGNED (TREE_OPERAND (op, 1)));