Thu Nov 27 00:59:46 1997 Jason Merrill <jason@yorick.cygnus.com>
+ * typeck.c (build_const_cast): Handle references here instead of
+ handing off to convert_to_reference.
+
* except.c: Lose Unexpected, SetTerminate, SetUnexpected,
TerminateFunctionCall.
(init_exception_processing): Likewise. Terminate et al are now
}
if (comp_ptr_ttypes_const (TREE_TYPE (type), intype))
- return (convert_from_reference
- (convert_to_reference (type, expr, CONV_CONST|CONV_IMPLICIT,
- LOOKUP_COMPLAIN, NULL_TREE)));
+ {
+ expr = build_unary_op (ADDR_EXPR, expr, 0);
+ expr = build1 (NOP_EXPR, type, expr);
+ return convert_from_reference (expr);
+ }
}
else if (TREE_CODE (type) == POINTER_TYPE
&& TREE_CODE (intype) == POINTER_TYPE