re PR libgcj/5671 (verify.cc problem merging local variables)

2002-02-13  Todd Stock  <toddastock@yahoo.com>

	Fix for PR libgcj/5671:
	* verify.cc (state::merge): Handle case where we're merging
	against an interface.

From-SVN: r49735
This commit is contained in:
Todd Stock 2002-02-13 17:12:27 +00:00 committed by Tom Tromey
parent 2dbe67bbfa
commit 1eca751e4b
2 changed files with 13 additions and 2 deletions

View file

@ -1,3 +1,9 @@
2002-02-13 Todd Stock <toddastock@yahoo.com>
Fix for PR libgcj/5671:
* verify.cc (state::merge): Handle case where we're merging
against an interface.
2002-02-12 Tom Tromey <tromey@redhat.com>
* exception.cc (std::abort): Mark as noreturn.

View file

@ -675,14 +675,19 @@ private:
oldk = oldk->getComponentType ();
}
// This loop will end when we hit Object.
while (true)
// Ordinarily this terminates when we hit Object...
while (k != NULL)
{
if (is_assignable_from_slow (k, oldk))
break;
k = k->getSuperclass ();
changed = true;
}
// ... but K could have been an interface, in which
// case we'll end up here. We just convert this
// into Object.
if (k == NULL)
k = &java::lang::Object::class$;
if (changed)
{