summaryrefslogtreecommitdiff
path: root/gcc/cp/decl2.c
diff options
context:
space:
mode:
Diffstat (limited to 'gcc/cp/decl2.c')
-rw-r--r--gcc/cp/decl2.c5
1 files changed, 1 insertions, 4 deletions
diff --git a/gcc/cp/decl2.c b/gcc/cp/decl2.c
index 9eb6fd5c1ce..3e18c4a4c19 100644
--- a/gcc/cp/decl2.c
+++ b/gcc/cp/decl2.c
@@ -2190,10 +2190,7 @@ build_cleanup (tree decl)
if (TREE_CODE (type) == ARRAY_TYPE)
temp = decl;
else
- {
- cxx_mark_addressable (decl);
- temp = build1 (ADDR_EXPR, build_pointer_type (type), decl);
- }
+ temp = build_address (decl);
temp = build_delete (TREE_TYPE (temp), temp,
sfk_complete_destructor,
LOOKUP_NORMAL|LOOKUP_NONVIRTUAL|LOOKUP_DESTRUCTOR, 0);