[Bug c++/78765] [7 Regression] ICE on invalid C++ code on x86_64-linux-gnu (internal compiler error: in cp_build_addr_expr_1, at cp/typeck.c:5708)

mpolacek at gcc dot gnu.org gcc-bugzilla@gcc.gnu.org
Tue Dec 13 12:27:00 GMT 2016


https://gcc.gnu.org/bugzilla/show_bug.cgi?id=78765

Marek Polacek <mpolacek at gcc dot gnu.org> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
                 CC|                            |mpolacek at gcc dot gnu.org

--- Comment #2 from Marek Polacek <mpolacek at gcc dot gnu.org> ---
The new code in cp_build_addr_expr_1 says
    CASE_CONVERT:
    case FLOAT_EXPR:
    case FIX_TRUNC_EXPR:
      /* We should have handled this above in the lvalue_kind check.  */
we arrived here with NOP_EXPR, but we hadn't issued an error in this block:
  /* Anything not already handled and not a true memory reference
     is an error.  */
  if (TREE_CODE (argtype) != FUNCTION_TYPE
      && TREE_CODE (argtype) != METHOD_TYPE)
because strict_lvalue is false.  ARG is (const struct ValueType) doubleval.


More information about the Gcc-bugs mailing list