Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(95)

Unified Diff: src/runtime.cc

Issue 19638003: Handlify Accessors::FunctionGetArguments method. (Closed) Base URL: https://v8.googlecode.com/svn/branches/bleeding_edge
Patch Set: Minor adjustments. Created 7 years, 5 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
« src/accessors.cc ('K') | « src/deoptimizer.cc ('k') | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: src/runtime.cc
diff --git a/src/runtime.cc b/src/runtime.cc
index c22a7f65a8a3e37fa292ff03eca8abc371144b1a..71487de5ba4961d05fee83a029c50b2dd06a0314 100644
--- a/src/runtime.cc
+++ b/src/runtime.cc
@@ -12484,8 +12484,7 @@ RUNTIME_FUNCTION(MaybeObject*, Runtime_ClearStepping) {
static Handle<JSObject> MaterializeArgumentsObject(
Isolate* isolate,
Handle<JSObject> target,
- Handle<JSFunction> function,
- FrameInspector* frame_inspector) {
+ Handle<JSFunction> function) {
// Do not materialize the arguments object for eval or top-level code.
// Skip if "arguments" is already taken.
if (!function->shared()->is_function() ||
@@ -12493,10 +12492,9 @@ static Handle<JSObject> MaterializeArgumentsObject(
return target;
}
- // FunctionGetArguments can't return a non-Object.
- Handle<JSObject> arguments(JSObject::cast(
- Accessors::FunctionGetArguments(frame_inspector->GetFunction(),
- NULL)->ToObjectUnchecked()), isolate);
+ // FunctionGetArguments can't throw an exception.
+ Handle<JSObject> arguments = Handle<JSObject>::cast(
+ Accessors::FunctionGetArguments(function));
SetProperty(isolate,
target,
isolate->factory()->arguments_string(),
@@ -12600,8 +12598,7 @@ RUNTIME_FUNCTION(MaybeObject*, Runtime_DebugEvaluate) {
isolate, materialized, function, &frame_inspector);
RETURN_IF_EMPTY_HANDLE(isolate, materialized);
- materialized = MaterializeArgumentsObject(
- isolate, materialized, function, &frame_inspector);
+ materialized = MaterializeArgumentsObject(isolate, materialized, function);
RETURN_IF_EMPTY_HANDLE(isolate, materialized);
// Add the materialized object in a with-scope to shadow the stack locals.
« src/accessors.cc ('K') | « src/deoptimizer.cc ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698