OLD | NEW |
1 // Copyright 2015 the V8 project authors. All rights reserved. | 1 // Copyright 2015 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_OBJECTS_H_ | 5 #ifndef V8_OBJECTS_H_ |
6 #define V8_OBJECTS_H_ | 6 #define V8_OBJECTS_H_ |
7 | 7 |
8 #include <iosfwd> | 8 #include <iosfwd> |
9 #include <memory> | 9 #include <memory> |
10 | 10 |
(...skipping 7866 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
7877 DECLARE_VERIFIER(Module) | 7877 DECLARE_VERIFIER(Module) |
7878 DECLARE_PRINTER(Module) | 7878 DECLARE_PRINTER(Module) |
7879 | 7879 |
7880 // The code representing this Module, either a | 7880 // The code representing this Module, either a |
7881 // SharedFunctionInfo or a JSFunction depending | 7881 // SharedFunctionInfo or a JSFunction depending |
7882 // on whether it's been instantiated. | 7882 // on whether it's been instantiated. |
7883 DECL_ACCESSORS(code, Object) | 7883 DECL_ACCESSORS(code, Object) |
7884 | 7884 |
7885 DECL_ACCESSORS(exports, ObjectHashTable) | 7885 DECL_ACCESSORS(exports, ObjectHashTable) |
7886 | 7886 |
| 7887 // [[RequestedModules]]: Modules imported or re-exported by this module. |
| 7888 // Corresponds 1-to-1 to the module specifier strings in |
| 7889 // ModuleInfo::module_requests. |
| 7890 DECL_ACCESSORS(requested_modules, FixedArray) |
| 7891 |
7887 static void CreateExport(Handle<Module> module, Handle<String> name); | 7892 static void CreateExport(Handle<Module> module, Handle<String> name); |
7888 static void StoreExport(Handle<Module> module, Handle<String> name, | 7893 static void StoreExport(Handle<Module> module, Handle<String> name, |
7889 Handle<Object> value); | 7894 Handle<Object> value); |
7890 static Handle<Object> LoadExport(Handle<Module> module, Handle<String> name); | 7895 static Handle<Object> LoadExport(Handle<Module> module, Handle<String> name); |
7891 | 7896 |
7892 static const int kCodeOffset = HeapObject::kHeaderSize; | 7897 static const int kCodeOffset = HeapObject::kHeaderSize; |
7893 static const int kExportsOffset = kCodeOffset + kPointerSize; | 7898 static const int kExportsOffset = kCodeOffset + kPointerSize; |
7894 static const int kSize = kExportsOffset + kPointerSize; | 7899 static const int kRequestedModulesOffset = kExportsOffset + kPointerSize; |
| 7900 static const int kSize = kRequestedModulesOffset + kPointerSize; |
7895 | 7901 |
7896 private: | 7902 private: |
7897 DISALLOW_IMPLICIT_CONSTRUCTORS(Module); | 7903 DISALLOW_IMPLICIT_CONSTRUCTORS(Module); |
7898 }; | 7904 }; |
7899 | 7905 |
7900 // JSBoundFunction describes a bound function exotic object. | 7906 // JSBoundFunction describes a bound function exotic object. |
7901 class JSBoundFunction : public JSObject { | 7907 class JSBoundFunction : public JSObject { |
7902 public: | 7908 public: |
7903 // [bound_target_function]: The wrapped function object. | 7909 // [bound_target_function]: The wrapped function object. |
7904 DECL_ACCESSORS(bound_target_function, JSReceiver) | 7910 DECL_ACCESSORS(bound_target_function, JSReceiver) |
(...skipping 3406 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
11311 } | 11317 } |
11312 return value; | 11318 return value; |
11313 } | 11319 } |
11314 }; | 11320 }; |
11315 | 11321 |
11316 | 11322 |
11317 } // NOLINT, false-positive due to second-order macros. | 11323 } // NOLINT, false-positive due to second-order macros. |
11318 } // NOLINT, false-positive due to second-order macros. | 11324 } // NOLINT, false-positive due to second-order macros. |
11319 | 11325 |
11320 #endif // V8_OBJECTS_H_ | 11326 #endif // V8_OBJECTS_H_ |
OLD | NEW |