Commit b55cb4a1 by Tom Tromey Committed by Tom Tromey

re PR java/20056 ('verification failed: incompatible type on stack' with --indirect-dispatch)

	PR java/20056:
	* verify.cc (type::equals): Fixed test.
	* testsuite/libjava.lang/PR20056.out: New file.
	* testsuite/libjava.lang/PR20056.java: New file.

From-SVN: r95266
parent e863ccf3
2005-02-18 Tom Tromey <tromey@redhat.com>
PR java/20056:
* verify.cc (type::equals): Fixed test.
* testsuite/libjava.lang/PR20056.out: New file.
* testsuite/libjava.lang/PR20056.java: New file.
2005-02-18 Bryce McKinlay <mckinlay@redhat.com>
* java/util/LinkedHashMap (addEntry): Call remove() with key argument,
......
public class PR20056 {
int x;
PR20056(int x) {}
PR20056(PR20056 f) {
// The verifier rejected the generated code in this case.
this(f.x = 0);
}
public static void main(String[] args)
{
System.out.println("maude");
}
}
......@@ -754,10 +754,10 @@ private:
bool equals (const type &other, _Jv_BytecodeVerifier *vfy)
{
// Only works for reference types.
if (key != reference_type
|| key != uninitialized_reference_type
|| other.key != reference_type
|| other.key != uninitialized_reference_type)
if ((key != reference_type
&& key != uninitialized_reference_type)
|| (other.key != reference_type
&& other.key != uninitialized_reference_type))
return false;
// Only for single-valued types.
if (klass->ref_next || other.klass->ref_next)
......
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