| OLD | NEW |
| 1 // Copyright 2014 the V8 project authors. All rights reserved. | 1 // Copyright 2014 the V8 project authors. All rights reserved. |
| 2 // Use of this source code is governed by a BSD-style license that can be | 2 // Use of this source code is governed by a BSD-style license that can be |
| 3 // found in the LICENSE file. | 3 // found in the LICENSE file. |
| 4 | 4 |
| 5 #ifndef V8_FACTORY_H_ | 5 #ifndef V8_FACTORY_H_ |
| 6 #define V8_FACTORY_H_ | 6 #define V8_FACTORY_H_ |
| 7 | 7 |
| 8 #include "src/globals.h" | 8 #include "src/globals.h" |
| 9 #include "src/isolate.h" | 9 #include "src/isolate.h" |
| 10 #include "src/messages.h" | 10 #include "src/messages.h" |
| (...skipping 704 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 715 static bool IsFunctionModeWithPrototype(FunctionMode function_mode) { | 715 static bool IsFunctionModeWithPrototype(FunctionMode function_mode) { |
| 716 return (function_mode == FUNCTION_WITH_WRITEABLE_PROTOTYPE || | 716 return (function_mode == FUNCTION_WITH_WRITEABLE_PROTOTYPE || |
| 717 function_mode == FUNCTION_WITH_READONLY_PROTOTYPE); | 717 function_mode == FUNCTION_WITH_READONLY_PROTOTYPE); |
| 718 } | 718 } |
| 719 | 719 |
| 720 Handle<Map> CreateSloppyFunctionMap(FunctionMode function_mode); | 720 Handle<Map> CreateSloppyFunctionMap(FunctionMode function_mode); |
| 721 | 721 |
| 722 Handle<Map> CreateStrictFunctionMap(FunctionMode function_mode, | 722 Handle<Map> CreateStrictFunctionMap(FunctionMode function_mode, |
| 723 Handle<JSFunction> empty_function); | 723 Handle<JSFunction> empty_function); |
| 724 | 724 |
| 725 Handle<Map> CreateClassFunctionMap(Handle<JSFunction> empty_function); |
| 726 |
| 725 // Allocates a new JSMessageObject object. | 727 // Allocates a new JSMessageObject object. |
| 726 Handle<JSMessageObject> NewJSMessageObject(MessageTemplate::Template message, | 728 Handle<JSMessageObject> NewJSMessageObject(MessageTemplate::Template message, |
| 727 Handle<Object> argument, | 729 Handle<Object> argument, |
| 728 int start_position, | 730 int start_position, |
| 729 int end_position, | 731 int end_position, |
| 730 Handle<Object> script, | 732 Handle<Object> script, |
| 731 Handle<Object> stack_frames); | 733 Handle<Object> stack_frames); |
| 732 | 734 |
| 733 Handle<DebugInfo> NewDebugInfo(Handle<SharedFunctionInfo> shared); | 735 Handle<DebugInfo> NewDebugInfo(Handle<SharedFunctionInfo> shared); |
| 734 | 736 |
| (...skipping 61 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 796 | 798 |
| 797 // Create a JSArray with no elements and no length. | 799 // Create a JSArray with no elements and no length. |
| 798 Handle<JSArray> NewJSArray(ElementsKind elements_kind, | 800 Handle<JSArray> NewJSArray(ElementsKind elements_kind, |
| 799 PretenureFlag pretenure = NOT_TENURED); | 801 PretenureFlag pretenure = NOT_TENURED); |
| 800 | 802 |
| 801 void SetFunctionInstanceDescriptor(Handle<Map> map, | 803 void SetFunctionInstanceDescriptor(Handle<Map> map, |
| 802 FunctionMode function_mode); | 804 FunctionMode function_mode); |
| 803 | 805 |
| 804 void SetStrictFunctionInstanceDescriptor(Handle<Map> map, | 806 void SetStrictFunctionInstanceDescriptor(Handle<Map> map, |
| 805 FunctionMode function_mode); | 807 FunctionMode function_mode); |
| 808 |
| 809 void SetClassFunctionInstanceDescriptor(Handle<Map> map); |
| 806 }; | 810 }; |
| 807 | 811 |
| 808 } // namespace internal | 812 } // namespace internal |
| 809 } // namespace v8 | 813 } // namespace v8 |
| 810 | 814 |
| 811 #endif // V8_FACTORY_H_ | 815 #endif // V8_FACTORY_H_ |
| OLD | NEW |