8139163: InstanceKlass::cast passes through NULL

Reduce raw (InstanceKlass*) casts and InstanceKlass::cast, which no long allows null

Reviewed-by: twisti, kbarrett
This commit is contained in:
Coleen Phillimore 2015-10-26 13:11:36 -04:00
parent 25cc742a8f
commit 5179fc3488
43 changed files with 215 additions and 252 deletions

View file

@ -1,5 +1,5 @@
/*
* Copyright (c) 2011, Oracle and/or its affiliates. All rights reserved.
* Copyright (c) 2011, 2015, Oracle and/or its affiliates. All rights reserved.
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
*
* This code is free software; you can redistribute it and/or modify it
@ -72,7 +72,7 @@ void JVMCICompiler::bootstrap() {
}
jlong start = os::javaTimeMillis();
Array<Method*>* objectMethods = InstanceKlass::cast(SystemDictionary::Object_klass())->methods();
Array<Method*>* objectMethods = SystemDictionary::Object_klass()->methods();
// Initialize compile queue with a selected set of methods.
int len = objectMethods->length();
for (int i = 0; i < len; i++) {