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

Side by Side Diff: src/ast/variables.cc

Issue 2061173002: [cleanup] Remove dead code from DeclareLookupSlot and rename it (Closed) Base URL: https://chromium.googlesource.com/v8/v8.git@master
Patch Set: Handled review comments Created 4 years, 6 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/ast/variables.h ('k') | src/compiler/ast-graph-builder.cc » ('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 2011 the V8 project authors. All rights reserved. 1 // Copyright 2011 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 #include "src/ast/variables.h" 5 #include "src/ast/variables.h"
6 6
7 #include "src/ast/ast.h" 7 #include "src/ast/ast.h"
8 #include "src/ast/scopes.h" 8 #include "src/ast/scopes.h"
9 9
10 namespace v8 { 10 namespace v8 {
(...skipping 22 matching lines...) Expand all
33 Kind kind, InitializationFlag initialization_flag, 33 Kind kind, InitializationFlag initialization_flag,
34 MaybeAssignedFlag maybe_assigned_flag) 34 MaybeAssignedFlag maybe_assigned_flag)
35 : scope_(scope), 35 : scope_(scope),
36 name_(name), 36 name_(name),
37 mode_(mode), 37 mode_(mode),
38 kind_(kind), 38 kind_(kind),
39 location_(VariableLocation::UNALLOCATED), 39 location_(VariableLocation::UNALLOCATED),
40 index_(-1), 40 index_(-1),
41 initializer_position_(RelocInfo::kNoPosition), 41 initializer_position_(RelocInfo::kNoPosition),
42 local_if_not_shadowed_(NULL), 42 local_if_not_shadowed_(NULL),
43 is_from_eval_(false),
44 force_context_allocation_(false), 43 force_context_allocation_(false),
45 is_used_(false), 44 is_used_(false),
46 initialization_flag_(initialization_flag), 45 initialization_flag_(initialization_flag),
47 maybe_assigned_(maybe_assigned_flag) { 46 maybe_assigned_(maybe_assigned_flag) {
48 // Var declared variables never need initialization. 47 // Var declared variables never need initialization.
49 DCHECK(!(mode == VAR && initialization_flag == kNeedsInitialization)); 48 DCHECK(!(mode == VAR && initialization_flag == kNeedsInitialization));
50 } 49 }
51 50
52 51
53 bool Variable::IsGlobalObjectProperty() const { 52 bool Variable::IsGlobalObjectProperty() const {
(...skipping 15 matching lines...) Expand all
69 68
70 int Variable::CompareIndex(Variable* const* v, Variable* const* w) { 69 int Variable::CompareIndex(Variable* const* v, Variable* const* w) {
71 int x = (*v)->index(); 70 int x = (*v)->index();
72 int y = (*w)->index(); 71 int y = (*w)->index();
73 // Consider sorting them according to type as well? 72 // Consider sorting them according to type as well?
74 return x - y; 73 return x - y;
75 } 74 }
76 75
77 } // namespace internal 76 } // namespace internal
78 } // namespace v8 77 } // namespace v8
OLDNEW
« no previous file with comments | « src/ast/variables.h ('k') | src/compiler/ast-graph-builder.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698