X-Git-Url: http://git.sourceforge.jp/view?a=blobdiff_plain;f=gcc%2Fc-typeck.c;h=4c55e587de3c9a5c82943ba52e5fda60325a4a57;hb=80f96752696cb2e7066add579aec8036e44870a7;hp=1b2b858582399826bb35183ab5218f9f5ca83eea;hpb=9e072631954f2a99c0e65ea3ebb59a9e83594422;p=pf3gnuchains%2Fgcc-fork.git diff --git a/gcc/c-typeck.c b/gcc/c-typeck.c index 1b2b8585823..4c55e587de3 100644 --- a/gcc/c-typeck.c +++ b/gcc/c-typeck.c @@ -4033,12 +4033,12 @@ build_conditional_expr (location_t colon_loc, tree ifexp, bool ifexp_bcp, /* Merge const and volatile flags of the incoming types. */ result_type = build_type_variant (result_type, - TREE_READONLY (op1) || TREE_READONLY (op2), - TREE_THIS_VOLATILE (op1) || TREE_THIS_VOLATILE (op2)); + TYPE_READONLY (type1) || TYPE_READONLY (type2), + TYPE_VOLATILE (type1) || TYPE_VOLATILE (type2)); - if (result_type != TREE_TYPE (op1)) + if (result_type != type1) op1 = convert_and_check (result_type, op1); - if (result_type != TREE_TYPE (op2)) + if (result_type != type2) op2 = convert_and_check (result_type, op2); if (ifexp_bcp && ifexp == truthvalue_true_node)