--- a/hotspot/src/share/vm/ci/ciObject.hpp Tue Jan 05 13:05:58 2010 +0100
+++ b/hotspot/src/share/vm/ci/ciObject.hpp Tue Jan 05 15:21:25 2010 +0100
@@ -131,10 +131,12 @@
// What kind of ciObject is this?
virtual bool is_null_object() const { return false; }
+ virtual bool is_call_site() const { return false; }
virtual bool is_cpcache() const { return false; }
virtual bool is_instance() { return false; }
virtual bool is_method() { return false; }
virtual bool is_method_data() { return false; }
+ virtual bool is_method_handle() const { return false; }
virtual bool is_array() { return false; }
virtual bool is_obj_array() { return false; }
virtual bool is_type_array() { return false; }
@@ -186,6 +188,10 @@
assert(is_null_object(), "bad cast");
return (ciNullObject*)this;
}
+ ciCallSite* as_call_site() {
+ assert(is_call_site(), "bad cast");
+ return (ciCallSite*) this;
+ }
ciCPCache* as_cpcache() {
assert(is_cpcache(), "bad cast");
return (ciCPCache*) this;
@@ -202,6 +208,10 @@
assert(is_method_data(), "bad cast");
return (ciMethodData*)this;
}
+ ciMethodHandle* as_method_handle() {
+ assert(is_method_handle(), "bad cast");
+ return (ciMethodHandle*) this;
+ }
ciArray* as_array() {
assert(is_array(), "bad cast");
return (ciArray*)this;