Commit 31fc696c by Ranjit Mathew Committed by Ranjit Mathew

re PR java/19070 (internal compiler error: in generate_bytecode_conditional, at…

re PR java/19070 (internal compiler error: in generate_bytecode_conditional, at java/jcf-write.c:1271)

        PR java/19070
        * parse.y (patch_binop): Allow comparisons against NULL only
        if the other operand is of a reference type.

From-SVN: r94205
parent 92e51459
2005-01-18 Ranjit Mathew <rmathew@hotmail.com>
PR java/19070
* parse.y (patch_binop): Allow comparisons against NULL only
if the other operand is of a reference type.
2005-01-24 Tom Tromey <tromey@redhat.com> 2005-01-24 Tom Tromey <tromey@redhat.com>
* java-tree.h (gcj_abi_version): Declare. * java-tree.h (gcj_abi_version): Declare.
......
/* Source code parsing and tree node generation for the GNU compiler /* Source code parsing and tree node generation for the GNU compiler
for the Java(TM) language. for the Java(TM) language.
Copyright (C) 1997, 1998, 1999, 2000, 2001, 2002, 2003, 2004 Copyright (C) 1997, 1998, 1999, 2000, 2001, 2002, 2003, 2004, 2005
Free Software Foundation, Inc. Free Software Foundation, Inc.
Contributed by Alexandre Petit-Bianco (apbianco@cygnus.com) Contributed by Alexandre Petit-Bianco (apbianco@cygnus.com)
...@@ -13798,7 +13798,9 @@ patch_binop (tree node, tree wfl_op1, tree wfl_op2) ...@@ -13798,7 +13798,9 @@ patch_binop (tree node, tree wfl_op1, tree wfl_op2)
/* Types have to be either references or the null type. If /* Types have to be either references or the null type. If
they're references, it must be possible to convert either they're references, it must be possible to convert either
type to the other by casting conversion. */ type to the other by casting conversion. */
else if (op1 == null_pointer_node || op2 == null_pointer_node else if ((op1 == null_pointer_node && op2 == null_pointer_node)
|| (op1 == null_pointer_node && JREFERENCE_TYPE_P (op2_type))
|| (JREFERENCE_TYPE_P (op1_type) && op2 == null_pointer_node)
|| (JREFERENCE_TYPE_P (op1_type) && JREFERENCE_TYPE_P (op2_type) || (JREFERENCE_TYPE_P (op1_type) && JREFERENCE_TYPE_P (op2_type)
&& (valid_ref_assignconv_cast_p (op1_type, op2_type, 1) && (valid_ref_assignconv_cast_p (op1_type, op2_type, 1)
|| valid_ref_assignconv_cast_p (op2_type, || valid_ref_assignconv_cast_p (op2_type,
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment