8080775: Better argument formatting for assert() and friends

Reviewed-by: kbarrett, pliden
This commit is contained in:
David Lindholm 2015-09-29 11:02:08 +02:00
parent aa0818a98a
commit 1e71f67736
225 changed files with 1342 additions and 1432 deletions

View file

@ -690,11 +690,11 @@ void Klass::oop_verify_on(oop obj, outputStream* st) {
bool Klass::verify_vtable_index(int i) {
if (oop_is_instance()) {
int limit = ((InstanceKlass*)this)->vtable_length()/vtableEntry::size();
assert(i >= 0 && i < limit, err_msg("index %d out of bounds %d", i, limit));
assert(i >= 0 && i < limit, "index %d out of bounds %d", i, limit);
} else {
assert(oop_is_array(), "Must be");
int limit = ((ArrayKlass*)this)->vtable_length()/vtableEntry::size();
assert(i >= 0 && i < limit, err_msg("index %d out of bounds %d", i, limit));
assert(i >= 0 && i < limit, "index %d out of bounds %d", i, limit);
}
return true;
}