From: Gabriel Dos Reis Date: Sun, 22 Feb 2004 16:27:38 +0000 (+0000) Subject: backport: re PR c++/13932 (duplicate warning message for conversion) X-Git-Tag: releases/gcc-3.3.4~244 X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=31df6f5ca33244e4e49d193995bcc719e46efdda;p=thirdparty%2Fgcc.git backport: re PR c++/13932 (duplicate warning message for conversion) Backport from mainline 2004-02-04 Mark Mitchell PR c++/13932 * call.c (convert_like_real): Use "converting" rather than "argument" as the descriptive keyword to dubious_conversion_warnings. * typeck.c (convert_for_assignment): Do not call dubious_conversion_warnings. From-SVN: r78264 --- diff --git a/gcc/cp/ChangeLog b/gcc/cp/ChangeLog index 4415bda7aa70..4feed3fa4e82 100644 --- a/gcc/cp/ChangeLog +++ b/gcc/cp/ChangeLog @@ -1,3 +1,14 @@ +2004-02-22 Gabriel Dos Reis + + Backport from mainline + 2004-02-04 Mark Mitchell + PR c++/13932 + * call.c (convert_like_real): Use "converting" rather than + "argument" as the descriptive keyword to + dubious_conversion_warnings. + * typeck.c (convert_for_assignment): Do not call + dubious_conversion_warnings. + 2004-02-22 Gabriel Dos Reis Backport from mainline diff --git a/gcc/cp/call.c b/gcc/cp/call.c index 89fc25790f24..9971c3305d60 100644 --- a/gcc/cp/call.c +++ b/gcc/cp/call.c @@ -4097,7 +4097,7 @@ convert_like_real (tree convs, tree expr, tree fn, int argnum, int inner, if (issue_conversion_warnings) expr = dubious_conversion_warnings - (totype, expr, "argument", fn, argnum); + (totype, expr, "converting", fn, argnum); switch (TREE_CODE (convs)) { case USER_CONV: diff --git a/gcc/cp/typeck.c b/gcc/cp/typeck.c index a306b17c2982..98da207a922b 100644 --- a/gcc/cp/typeck.c +++ b/gcc/cp/typeck.c @@ -5937,8 +5937,6 @@ convert_for_assignment (type, rhs, errtype, fndecl, parmnum) if (TREE_CODE (rhs) == TREE_LIST && TREE_VALUE (rhs) == error_mark_node) return error_mark_node; - rhs = dubious_conversion_warnings (type, rhs, errtype, fndecl, parmnum); - /* The RHS of an assignment cannot have void type. */ if (coder == VOID_TYPE) {