}
+bool JavaScriptFrame::HasInlinedFrames() {
+ List<JSFunction*> functions(1);
+ GetFunctions(&functions);
+ return functions.length() > 1;
+}
+
+
Object* JavaScriptFrame::GetOriginalConstructor() const {
Address fp = caller_fp();
if (has_adapted_arguments()) {
// Check if this frame is a constructor frame invoked through 'new'.
bool IsConstructor() const;
+ // Determines whether this frame includes inlined activations. To get details
+ // about the inlined frames use {GetFunctions} and {Summarize}.
+ bool HasInlinedFrames();
+
// Returns the original constructor function that was used in the constructor
// call to this frame. Note that this is only valid on constructor frames.
Object* GetOriginalConstructor() const;
CONVERT_ARG_HANDLE_CHECKED(JSFunction, callee, 0);
Object** parameters = reinterpret_cast<Object**>(args[1]);
CONVERT_SMI_ARG_CHECKED(argument_count, 2);
+#ifdef DEBUG
+ // This runtime function does not materialize the correct arguments when the
+ // caller has been inlined, better make sure we are not hitting that case.
+ JavaScriptFrameIterator it(isolate);
+ DCHECK(!it.frame()->HasInlinedFrames());
+#endif // DEBUG
return *NewSloppyArguments(isolate, callee, parameters, argument_count);
}
CONVERT_ARG_HANDLE_CHECKED(JSFunction, callee, 0)
Object** parameters = reinterpret_cast<Object**>(args[1]);
CONVERT_SMI_ARG_CHECKED(argument_count, 2);
+#ifdef DEBUG
+ // This runtime function does not materialize the correct arguments when the
+ // caller has been inlined, better make sure we are not hitting that case.
+ JavaScriptFrameIterator it(isolate);
+ DCHECK(!it.frame()->HasInlinedFrames());
+#endif // DEBUG
return *NewStrictArguments(isolate, callee, parameters, argument_count);
}