summaryrefslogtreecommitdiff
path: root/gcc/cp/call.c
diff options
context:
space:
mode:
Diffstat (limited to 'gcc/cp/call.c')
-rw-r--r--gcc/cp/call.c3
1 files changed, 1 insertions, 2 deletions
diff --git a/gcc/cp/call.c b/gcc/cp/call.c
index 99f9cc3d25a..2eab78266f8 100644
--- a/gcc/cp/call.c
+++ b/gcc/cp/call.c
@@ -7062,8 +7062,7 @@ build_special_member_call (tree instance, tree name, VEC(tree,gc) **args,
current_vtt_parm,
vtt);
gcc_assert (BINFO_SUBVTT_INDEX (binfo));
- sub_vtt = build2 (POINTER_PLUS_EXPR, TREE_TYPE (vtt), vtt,
- BINFO_SUBVTT_INDEX (binfo));
+ sub_vtt = fold_build_pointer_plus (vtt, BINFO_SUBVTT_INDEX (binfo));
if (args == NULL)
{