OLD | NEW |
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/scopeinfo.h" |
| 6 |
5 #include <stdlib.h> | 7 #include <stdlib.h> |
6 | 8 |
7 #include "src/v8.h" | |
8 | |
9 #include "src/bootstrapper.h" | 9 #include "src/bootstrapper.h" |
10 #include "src/scopeinfo.h" | |
11 #include "src/scopes.h" | 10 #include "src/scopes.h" |
12 | 11 |
13 namespace v8 { | 12 namespace v8 { |
14 namespace internal { | 13 namespace internal { |
15 | 14 |
16 | 15 |
17 Handle<ScopeInfo> ScopeInfo::Create(Isolate* isolate, Zone* zone, | 16 Handle<ScopeInfo> ScopeInfo::Create(Isolate* isolate, Zone* zone, |
18 Scope* scope) { | 17 Scope* scope) { |
19 // Collect stack and context locals. | 18 // Collect stack and context locals. |
20 ZoneList<Variable*> stack_locals(scope->StackLocalCount(), zone); | 19 ZoneList<Variable*> stack_locals(scope->StackLocalCount(), zone); |
(...skipping 809 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
830 info->set_mode(i, var->mode()); | 829 info->set_mode(i, var->mode()); |
831 DCHECK(var->index() >= 0); | 830 DCHECK(var->index() >= 0); |
832 info->set_index(i, var->index()); | 831 info->set_index(i, var->index()); |
833 } | 832 } |
834 DCHECK(i == info->length()); | 833 DCHECK(i == info->length()); |
835 return info; | 834 return info; |
836 } | 835 } |
837 | 836 |
838 } // namespace internal | 837 } // namespace internal |
839 } // namespace v8 | 838 } // namespace v8 |
OLD | NEW |