Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(86)

Side by Side Diff: src/objects/module-info.h

Issue 2638893002: objects.h splitting: Move ModuleInfoEntry (Closed)
Patch Set: dropping unnecessary undefs Created 3 years, 11 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch
« no previous file with comments | « src/objects.h ('k') | src/objects/object-macros.h » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright 2017 the V8 project authors. All rights reserved. 1 // Copyright 2017 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_MODULE_INFO_H_ 5 #ifndef V8_OBJECTS_MODULE_INFO_H_
6 #define V8_OBJECTS_MODULE_INFO_H_ 6 #define V8_OBJECTS_MODULE_INFO_H_
7 7
8 #include "src/objects.h" 8 #include "src/objects.h"
9 9
10 // Has to be the last include (doesn't have include guards): 10 // Has to be the last include (doesn't have include guards):
(...skipping 69 matching lines...) Expand 10 before | Expand all | Expand 10 after
80 }; 80 };
81 enum { 81 enum {
82 kRegularExportLocalNameOffset, 82 kRegularExportLocalNameOffset,
83 kRegularExportCellIndexOffset, 83 kRegularExportCellIndexOffset,
84 kRegularExportExportNamesOffset, 84 kRegularExportExportNamesOffset,
85 kRegularExportLength 85 kRegularExportLength
86 }; 86 };
87 DISALLOW_IMPLICIT_CONSTRUCTORS(ModuleInfo); 87 DISALLOW_IMPLICIT_CONSTRUCTORS(ModuleInfo);
88 }; 88 };
89 89
90 class ModuleInfoEntry : public Struct {
91 public:
92 DECLARE_CAST(ModuleInfoEntry)
93 DECLARE_PRINTER(ModuleInfoEntry)
94 DECLARE_VERIFIER(ModuleInfoEntry)
95
96 DECL_ACCESSORS(export_name, Object)
97 DECL_ACCESSORS(local_name, Object)
98 DECL_ACCESSORS(import_name, Object)
99 DECL_INT_ACCESSORS(module_request)
100 DECL_INT_ACCESSORS(cell_index)
101 DECL_INT_ACCESSORS(beg_pos)
102 DECL_INT_ACCESSORS(end_pos)
103
104 static Handle<ModuleInfoEntry> New(Isolate* isolate,
105 Handle<Object> export_name,
106 Handle<Object> local_name,
107 Handle<Object> import_name,
108 int module_request, int cell_index,
109 int beg_pos, int end_pos);
110
111 static const int kExportNameOffset = HeapObject::kHeaderSize;
112 static const int kLocalNameOffset = kExportNameOffset + kPointerSize;
113 static const int kImportNameOffset = kLocalNameOffset + kPointerSize;
114 static const int kModuleRequestOffset = kImportNameOffset + kPointerSize;
115 static const int kCellIndexOffset = kModuleRequestOffset + kPointerSize;
116 static const int kBegPosOffset = kCellIndexOffset + kPointerSize;
117 static const int kEndPosOffset = kBegPosOffset + kPointerSize;
118 static const int kSize = kEndPosOffset + kPointerSize;
119
120 private:
121 DISALLOW_IMPLICIT_CONSTRUCTORS(ModuleInfoEntry);
122 };
123
90 } // namespace internal 124 } // namespace internal
91 } // namespace v8 125 } // namespace v8
92 126
93 #include "src/objects/object-macros-undef.h" 127 #include "src/objects/object-macros-undef.h"
94 128
95 #endif // V8_OBJECTS_MODULE_INFO_H_ 129 #endif // V8_OBJECTS_MODULE_INFO_H_
OLDNEW
« no previous file with comments | « src/objects.h ('k') | src/objects/object-macros.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698