comparison src/share/vm/oops/klass.hpp @ 10265:92ef81e2f571

8003557: NPG: Klass* const k should be const Klass* k. Summary: With NPG, const KlassOop klass which is in fact a definition converted to Klass* const, which is not the original intention. The right usage is converting them to const Klass*. Reviewed-by: coleenp, kvn Contributed-by: yumin.qi@oracle.com
author minqi
date Fri, 10 May 2013 08:27:30 -0700
parents 3efdfd6ddbf2
children 43083e670adf
comparison
equal deleted inserted replaced
10262:c272092594bd 10265:92ef81e2f571
393 393
394 // vtables 394 // vtables
395 virtual klassVtable* vtable() const { return NULL; } 395 virtual klassVtable* vtable() const { return NULL; }
396 396
397 // subclass check 397 // subclass check
398 bool is_subclass_of(Klass* k) const; 398 bool is_subclass_of(const Klass* k) const;
399 // subtype check: true if is_subclass_of, or if k is interface and receiver implements it 399 // subtype check: true if is_subclass_of, or if k is interface and receiver implements it
400 bool is_subtype_of(Klass* k) const { 400 bool is_subtype_of(Klass* k) const {
401 juint off = k->super_check_offset(); 401 juint off = k->super_check_offset();
402 Klass* sup = *(Klass**)( (address)this + off ); 402 Klass* sup = *(Klass**)( (address)this + off );
403 const juint secondary_offset = in_bytes(secondary_super_cache_offset()); 403 const juint secondary_offset = in_bytes(secondary_super_cache_offset());