| Index: src/ia32/builtins-ia32.cc
|
| diff --git a/src/ia32/builtins-ia32.cc b/src/ia32/builtins-ia32.cc
|
| index 116d4c16a270f4f734aef73b0acf7b62ae4a43d5..9ee0315d057a64d1b69556d4a7993c66bb1a312d 100644
|
| --- a/src/ia32/builtins-ia32.cc
|
| +++ b/src/ia32/builtins-ia32.cc
|
| @@ -408,6 +408,13 @@ void Builtins::Generate_JSBuiltinsConstructStub(MacroAssembler* masm) {
|
| }
|
|
|
|
|
| +void Builtins::Generate_ConstructedNonConstructable(MacroAssembler* masm) {
|
| + FrameScope scope(masm, StackFrame::INTERNAL);
|
| + __ push(edi);
|
| + __ CallRuntime(Runtime::kThrowConstructedNonConstructable, 1);
|
| +}
|
| +
|
| +
|
| enum IsTagged { kEaxIsSmiTagged, kEaxIsUntaggedInt };
|
|
|
|
|
| @@ -1541,7 +1548,8 @@ void Builtins::Generate_CallFunction(MacroAssembler* masm,
|
| __ bind(&class_constructor);
|
| {
|
| FrameScope frame(masm, StackFrame::INTERNAL);
|
| - __ CallRuntime(Runtime::kThrowConstructorNonCallableError, 0);
|
| + __ push(edi);
|
| + __ CallRuntime(Runtime::kThrowConstructorNonCallableError, 1);
|
| }
|
| }
|
|
|
| @@ -1668,11 +1676,8 @@ void Builtins::Generate_Construct(MacroAssembler* masm) {
|
| // Called Construct on an Object that doesn't have a [[Construct]] internal
|
| // method.
|
| __ bind(&non_constructor);
|
| - {
|
| - FrameScope scope(masm, StackFrame::INTERNAL);
|
| - __ Push(edi);
|
| - __ CallRuntime(Runtime::kThrowCalledNonCallable, 1);
|
| - }
|
| + __ Jump(masm->isolate()->builtins()->ConstructedNonConstructable(),
|
| + RelocInfo::CODE_TARGET);
|
| }
|
|
|
|
|
|
|