summaryrefslogtreecommitdiffstats
path: root/gcc/cp/tree.c
diff options
context:
space:
mode:
authormrs <mrs@138bc75d-0d04-0410-961f-82ee72b054a4>1995-04-24 17:27:46 +0000
committermrs <mrs@138bc75d-0d04-0410-961f-82ee72b054a4>1995-04-24 17:27:46 +0000
commit3f7d79e4582e972e104146dcdb336a0a79eadbae (patch)
tree05387abeca235d05928bcbdd91eb5aa83da77407 /gcc/cp/tree.c
parent4bbe759e9bba699499e78bc6ee631be30ef43968 (diff)
downloadppe42-gcc-3f7d79e4582e972e104146dcdb336a0a79eadbae.tar.gz
ppe42-gcc-3f7d79e4582e972e104146dcdb336a0a79eadbae.zip
67th Cygnus<->FSF merge
git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@9433 138bc75d-0d04-0410-961f-82ee72b054a4
Diffstat (limited to 'gcc/cp/tree.c')
-rw-r--r--gcc/cp/tree.c12
1 files changed, 8 insertions, 4 deletions
diff --git a/gcc/cp/tree.c b/gcc/cp/tree.c
index 90c21b254f2..196f1a4e3ea 100644
--- a/gcc/cp/tree.c
+++ b/gcc/cp/tree.c
@@ -153,7 +153,7 @@ lvalue_p (ref)
return 1;
case CALL_EXPR:
- if (TREE_ADDRESSABLE (TREE_TYPE (ref)))
+ if (IS_AGGR_TYPE (TREE_TYPE (ref)))
return 1;
break;
@@ -217,9 +217,13 @@ build_cplus_new (type, init, with_cleanup_p)
tree init;
int with_cleanup_p;
{
- tree slot = build (VAR_DECL, type);
- tree rval = build (NEW_EXPR, type,
- TREE_OPERAND (init, 0), TREE_OPERAND (init, 1), slot);
+ tree slot;
+ tree rval;
+
+ slot = build (VAR_DECL, type);
+ layout_decl (slot, 0);
+ rval = build (NEW_EXPR, type,
+ TREE_OPERAND (init, 0), TREE_OPERAND (init, 1), slot);
TREE_SIDE_EFFECTS (rval) = 1;
TREE_ADDRESSABLE (rval) = 1;
rval = build (TARGET_EXPR, type, slot, rval, 0);
OpenPOWER on IntegriCloud