6904403: assert(f == k->has_finalizer(),"inconsistent has_finalizer") with debug VM

Don't assert if one of classes in hierarhy was redefined

Reviewed-by: coleenp, sspitsyn
This commit is contained in:
Dmitry Samersoff 2014-05-28 07:36:32 -07:00
parent 1a3734cdfa
commit c291efb1df
9 changed files with 273 additions and 4 deletions

View file

@ -754,6 +754,11 @@ class InstanceKlass: public Klass {
bool implements_interface(Klass* k) const;
bool is_same_or_direct_interface(Klass* k) const;
#ifdef ASSERT
// check whether this class or one of its superclasses was redefined
bool has_redefined_this_or_super() const;
#endif
// Access to the implementor of an interface.
Klass* implementor() const
{
@ -811,8 +816,8 @@ class InstanceKlass: public Klass {
// Casting from Klass*
static InstanceKlass* cast(Klass* k) {
assert(k->is_klass(), "must be");
assert(k->oop_is_instance(), "cast to InstanceKlass");
assert(k == NULL || k->is_klass(), "must be");
assert(k == NULL || k->oop_is_instance(), "cast to InstanceKlass");
return (InstanceKlass*) k;
}