Index: src/stub-cache.cc |
diff --git a/src/stub-cache.cc b/src/stub-cache.cc |
index 1f708b3ca63c94f6d7bf49e9c10d66e23f1de8ca..2cd65857814f241f8ed6481930f565ab8bf9e64e 100644 |
--- a/src/stub-cache.cc |
+++ b/src/stub-cache.cc |
@@ -1548,27 +1548,12 @@ CallOptimization::CallOptimization(LookupResult* lookup) { |
} |
} |
+ |
CallOptimization::CallOptimization(Handle<JSFunction> function) { |
Initialize(function); |
} |
-int CallOptimization::GetPrototypeDepthOfExpectedType( |
- Handle<JSObject> object, |
- Handle<JSObject> holder) const { |
- ASSERT(is_simple_api_call()); |
- if (expected_receiver_type_.is_null()) return 0; |
- int depth = 0; |
- while (!object.is_identical_to(holder)) { |
- if (object->IsInstanceOf(*expected_receiver_type_)) return depth; |
- object = Handle<JSObject>(JSObject::cast(object->GetPrototype())); |
- ++depth; |
- } |
- if (holder->IsInstanceOf(*expected_receiver_type_)) return depth; |
- return kInvalidProtoDepth; |
-} |
- |
- |
void CallOptimization::Initialize(Handle<JSFunction> function) { |
constant_function_ = Handle<JSFunction>::null(); |
is_simple_api_call_ = false; |