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

Side by Side Diff: src/ast/context-slot-cache.h

Issue 2758563002: [gn] Enable stricter build flags (Closed)
Patch Set: Address comment Created 3 years, 9 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/api.cc ('k') | src/ast/modules.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 2016 the V8 project authors. All rights reserved. 1 // Copyright 2016 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_AST_CONTEXT_SLOT_CACHE_H_ 5 #ifndef V8_AST_CONTEXT_SLOT_CACHE_H_
6 #define V8_AST_CONTEXT_SLOT_CACHE_H_ 6 #define V8_AST_CONTEXT_SLOT_CACHE_H_
7 7
8 #include "src/allocation.h" 8 #include "src/allocation.h"
9 #include "src/ast/modules.h" 9 #include "src/ast/modules.h"
10 10
(...skipping 20 matching lines...) Expand all
31 // Clear the cache. 31 // Clear the cache.
32 void Clear(); 32 void Clear();
33 33
34 static const int kNotFound = -2; 34 static const int kNotFound = -2;
35 35
36 private: 36 private:
37 ContextSlotCache() { 37 ContextSlotCache() {
38 for (int i = 0; i < kLength; ++i) { 38 for (int i = 0; i < kLength; ++i) {
39 keys_[i].data = NULL; 39 keys_[i].data = NULL;
40 keys_[i].name = NULL; 40 keys_[i].name = NULL;
41 values_[i] = kNotFound; 41 values_[i] = static_cast<uint32_t>(kNotFound);
42 } 42 }
43 } 43 }
44 44
45 inline static int Hash(Object* data, String* name); 45 inline static int Hash(Object* data, String* name);
46 46
47 #ifdef DEBUG 47 #ifdef DEBUG
48 void ValidateEntry(Handle<Object> data, Handle<String> name, 48 void ValidateEntry(Handle<Object> data, Handle<String> name,
49 VariableMode mode, InitializationFlag init_flag, 49 VariableMode mode, InitializationFlag init_flag,
50 MaybeAssignedFlag maybe_assigned_flag, int slot_index); 50 MaybeAssignedFlag maybe_assigned_flag, int slot_index);
51 #endif 51 #endif
(...skipping 51 matching lines...) Expand 10 before | Expand all | Expand 10 after
103 uint32_t values_[kLength]; 103 uint32_t values_[kLength];
104 104
105 friend class Isolate; 105 friend class Isolate;
106 DISALLOW_COPY_AND_ASSIGN(ContextSlotCache); 106 DISALLOW_COPY_AND_ASSIGN(ContextSlotCache);
107 }; 107 };
108 108
109 } // namespace internal 109 } // namespace internal
110 } // namespace v8 110 } // namespace v8
111 111
112 #endif // V8_AST_CONTEXT_SLOT_CACHE_H_ 112 #endif // V8_AST_CONTEXT_SLOT_CACHE_H_
OLDNEW
« no previous file with comments | « src/api.cc ('k') | src/ast/modules.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698