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

Side by Side Diff: pkg/compiler/lib/src/js_model/locals.dart

Issue 2975323002: Renamed some scoping classes to make their usage clearer. (Closed)
Patch Set: . Created 3 years, 5 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
OLDNEW
1 // Copyright (c) 2017, the Dart project authors. Please see the AUTHORS file 1 // Copyright (c) 2017, the Dart project authors. Please see the AUTHORS file
2 // for details. All rights reserved. Use of this source code is governed by a 2 // for details. All rights reserved. Use of this source code is governed by a
3 // BSD-style license that can be found in the LICENSE file. 3 // BSD-style license that can be found in the LICENSE file.
4 4
5 library dart2js.js_model.locals; 5 library dart2js.js_model.locals;
6 6
7 import 'package:kernel/ast.dart' as ir; 7 import 'package:kernel/ast.dart' as ir;
8 8
9 import '../closure.dart'; 9 import '../closure.dart';
10 import '../common.dart'; 10 import '../common.dart';
(...skipping 114 matching lines...) Expand 10 before | Expand all | Expand 10 after
125 } 125 }
126 126
127 @override 127 @override
128 Local getLocal(ir.VariableDeclaration node) { 128 Local getLocal(ir.VariableDeclaration node) {
129 return _map.putIfAbsent(node, () { 129 return _map.putIfAbsent(node, () {
130 return new JLocal(node.name, currentMember); 130 return new JLocal(node.name, currentMember);
131 }); 131 });
132 } 132 }
133 133
134 @override 134 @override
135 LoopClosureScope getLoopClosureScope( 135 CapturedLoopScope getCapturedLoopScope(
136 ClosureDataLookup closureLookup, ir.TreeNode node) { 136 ClosureDataLookup closureLookup, ir.TreeNode node) {
137 return closureLookup.getLoopClosureScope(node); 137 return closureLookup.getCapturedLoopScope(node);
138 } 138 }
139 } 139 }
140 140
141 class JumpVisitor extends ir.Visitor { 141 class JumpVisitor extends ir.Visitor {
142 int index = 0; 142 int index = 0;
143 final MemberEntity member; 143 final MemberEntity member;
144 final Map<ir.TreeNode, JJumpTarget> jumpTargetMap = 144 final Map<ir.TreeNode, JJumpTarget> jumpTargetMap =
145 <ir.TreeNode, JJumpTarget>{}; 145 <ir.TreeNode, JJumpTarget>{};
146 final Set<ir.BreakStatement> breaksAsContinue = new Set<ir.BreakStatement>(); 146 final Set<ir.BreakStatement> breaksAsContinue = new Set<ir.BreakStatement>();
147 147
(...skipping 122 matching lines...) Expand 10 before | Expand all | Expand 10 after
270 sb.write(memberContext.enclosingClass.name); 270 sb.write(memberContext.enclosingClass.name);
271 sb.write('.'); 271 sb.write('.');
272 } 272 }
273 sb.write(memberContext.name); 273 sb.write(memberContext.name);
274 sb.write('#'); 274 sb.write('#');
275 sb.write(name); 275 sb.write(name);
276 sb.write(')'); 276 sb.write(')');
277 return sb.toString(); 277 return sb.toString();
278 } 278 }
279 } 279 }
OLDNEW
« no previous file with comments | « pkg/compiler/lib/src/js_model/closure_visitors.dart ('k') | pkg/compiler/lib/src/kernel/element_map.dart » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698