Chromium Code Reviews| Index: src/bootstrapper.cc |
| diff --git a/src/bootstrapper.cc b/src/bootstrapper.cc |
| index c75961d4bb9357bbc2ca3d0720345813c71d1bb0..65f8dd97d51cde1e33be16ef291e25a0d8ecd8c9 100644 |
| --- a/src/bootstrapper.cc |
| +++ b/src/bootstrapper.cc |
| @@ -3583,6 +3583,17 @@ bool Genesis::InstallNatives(GlobalContextType context_type) { |
| InstallWithIntrinsicDefaultProto(isolate(), function, |
| Context::PROMISE_FUNCTION_INDEX); |
| + // TODO(gsathya): Fix up the wiring to be the correct Promise constructor. |
| + Handle<JSObject> prototype = |
| + factory()->NewJSObject(isolate()->object_function(), TENURED); |
| + Handle<JSFunction> promise2_fun = SimpleInstallFunction( |
| + global_object, "Promise2", Builtins::kPromiseConstructor, 1, false); |
|
Benedikt Meurer
2016/11/11 06:50:30
You cannot say "dont adapt" arguments here, but ha
gsathya
2016/11/22 04:31:43
Done.
|
| + |
| + Handle<SharedFunctionInfo> shared(promise2_fun->shared(), isolate()); |
| + shared->SetConstructStub(*isolate()->builtins()->PromiseConstructor()); |
|
Benedikt Meurer
2016/11/11 06:50:30
I'm not sure we currently support having a TFS bui
gsathya
2016/11/22 04:31:43
Done.
|
| + shared->set_instance_class_name(isolate()->heap()->Promise_string()); |
| + shared->DontAdaptArguments(); |
|
Benedikt Meurer
2016/11/11 06:50:30
This is reundant (and wrong).
gsathya
2016/11/22 04:31:43
Done.
|
| + |
| { |
| Handle<Code> code = handle( |
| isolate()->builtins()->builtin(Builtins::kPromiseResolveClosure), |