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/isolate.h" | 8 #include "src/isolate.h" |
9 #include "src/messages.h" | 9 #include "src/messages.h" |
10 #include "src/type-feedback-vector.h" | 10 #include "src/type-feedback-vector.h" |
(...skipping 499 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
510 Handle<JSFunction> NewFunction(Handle<String> name, Handle<Code> code, | 510 Handle<JSFunction> NewFunction(Handle<String> name, Handle<Code> code, |
511 Handle<Object> prototype, InstanceType type, | 511 Handle<Object> prototype, InstanceType type, |
512 int instance_size, | 512 int instance_size, |
513 bool read_only_prototype = false, | 513 bool read_only_prototype = false, |
514 bool install_constructor = false, | 514 bool install_constructor = false, |
515 bool is_strict = false); | 515 bool is_strict = false); |
516 Handle<JSFunction> NewFunction(Handle<String> name, | 516 Handle<JSFunction> NewFunction(Handle<String> name, |
517 Handle<Code> code, | 517 Handle<Code> code, |
518 InstanceType type, | 518 InstanceType type, |
519 int instance_size); | 519 int instance_size); |
| 520 Handle<JSFunction> NewFunction(Handle<Map> map, Handle<String> name, |
| 521 MaybeHandle<Code> maybe_code); |
520 | 522 |
521 // Create a serialized scope info. | 523 // Create a serialized scope info. |
522 Handle<ScopeInfo> NewScopeInfo(int length); | 524 Handle<ScopeInfo> NewScopeInfo(int length); |
523 | 525 |
524 // Create an External object for V8's external API. | 526 // Create an External object for V8's external API. |
525 Handle<JSObject> NewExternal(void* value); | 527 Handle<JSObject> NewExternal(void* value); |
526 | 528 |
527 // The reference to the Code object is stored in self_reference. | 529 // The reference to the Code object is stored in self_reference. |
528 // This allows generated code to reference its own Code object | 530 // This allows generated code to reference its own Code object |
529 // by containing this handle. | 531 // by containing this handle. |
(...skipping 158 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
688 Handle<Object> GetNumberStringCache(Handle<Object> number); | 690 Handle<Object> GetNumberStringCache(Handle<Object> number); |
689 | 691 |
690 // Update the cache with a new number-string pair. | 692 // Update the cache with a new number-string pair. |
691 void SetNumberStringCache(Handle<Object> number, Handle<String> string); | 693 void SetNumberStringCache(Handle<Object> number, Handle<String> string); |
692 | 694 |
693 // Creates a function initialized with a shared part. | 695 // Creates a function initialized with a shared part. |
694 Handle<JSFunction> NewFunction(Handle<Map> map, | 696 Handle<JSFunction> NewFunction(Handle<Map> map, |
695 Handle<SharedFunctionInfo> info, | 697 Handle<SharedFunctionInfo> info, |
696 Handle<Context> context, | 698 Handle<Context> context, |
697 PretenureFlag pretenure = TENURED); | 699 PretenureFlag pretenure = TENURED); |
698 | |
699 Handle<JSFunction> NewFunction(Handle<Map> map, | |
700 Handle<String> name, | |
701 MaybeHandle<Code> maybe_code); | |
702 }; | 700 }; |
703 | 701 |
704 } // namespace internal | 702 } // namespace internal |
705 } // namespace v8 | 703 } // namespace v8 |
706 | 704 |
707 #endif // V8_FACTORY_H_ | 705 #endif // V8_FACTORY_H_ |
OLD | NEW |