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

Unified Diff: src/execution.cc

Issue 7035007: Implement get trap for proxies. (Closed) Base URL: https://v8.googlecode.com/svn/branches/bleeding_edge
Patch Set: Implementing get trap for proxies. Created 9 years, 7 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
« no previous file with comments | « src/execution.h ('k') | src/factory.h » ('j') | src/messages.js » ('J')
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: src/execution.cc
diff --git a/src/execution.cc b/src/execution.cc
index db74492316103971ced0d1c27257ff1ecd1caed3..745a01512a5fd713478a8eb378d353782dbb1d86 100644
--- a/src/execution.cc
+++ b/src/execution.cc
@@ -145,11 +145,16 @@ static Handle<Object> Invoke(bool construct,
}
-Handle<Object> Execution::Call(Handle<JSFunction> func,
+Handle<Object> Execution::Call(Handle<Object> callable,
Handle<Object> receiver,
int argc,
Object*** args,
bool* pending_exception) {
+ if (!callable->IsJSFunction()) {
+ callable = TryGetFunctionDelegate(callable, pending_exception);
+ if (*pending_exception) return callable;
+ }
+ Handle<JSFunction> func(JSFunction::cast(*callable));
Kevin Millikin (Chromium) 2011/05/16 15:21:41 Should be Handle<JSFunction> func = Handle<JSFunc
rossberg 2011/05/16 15:54:37 Done.
return Invoke(false, func, receiver, argc, args, pending_exception);
}
« no previous file with comments | « src/execution.h ('k') | src/factory.h » ('j') | src/messages.js » ('J')

Powered by Google App Engine
This is Rietveld 408576698