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

Side by Side Diff: pkg/compiler/lib/src/kernel/element_map.dart

Issue 2968383002: Add ConstructorBodyEntity (Closed)
Patch Set: Skip non-live constructor bodies 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 import 'package:kernel/ast.dart' as ir; 5 import 'package:kernel/ast.dart' as ir;
6 6
7 import '../closure.dart'; 7 import '../closure.dart';
8 import '../common.dart'; 8 import '../common.dart';
9 import '../constants/values.dart'; 9 import '../constants/values.dart';
10 import '../common_elements.dart'; 10 import '../common_elements.dart';
(...skipping 170 matching lines...) Expand 10 before | Expand all | Expand 10 after
181 /// the initializer is not a constant expression. 181 /// the initializer is not a constant expression.
182 ConstantValue getFieldConstantValue(ir.Field field); 182 ConstantValue getFieldConstantValue(ir.Field field);
183 183
184 /// Returns the `noSuchMethod` [FunctionEntity] call from a 184 /// Returns the `noSuchMethod` [FunctionEntity] call from a
185 /// `super.noSuchMethod` invocation within [cls]. 185 /// `super.noSuchMethod` invocation within [cls].
186 FunctionEntity getSuperNoSuchMethod(ClassEntity cls); 186 FunctionEntity getSuperNoSuchMethod(ClassEntity cls);
187 187
188 /// Returns a [Spannable] for a message pointing to the IR [node] in the 188 /// Returns a [Spannable] for a message pointing to the IR [node] in the
189 /// context of [member]. 189 /// context of [member].
190 Spannable getSpannable(MemberEntity member, ir.Node node); 190 Spannable getSpannable(MemberEntity member, ir.Node node);
191
192 /// Returns the constructor body entity corresponding to [constructor].
193 FunctionEntity getConstructorBody(ir.Constructor node);
194
195 /// Returns the uri for the deferred import [node].
196 // TODO(johnniwinther): Avoid this method by deriving the uri directly from
197 // the node.
198 String getDeferredUri(ir.LibraryDependency node);
191 } 199 }
192 200
193 /// Kinds of foreign functions. 201 /// Kinds of foreign functions.
194 enum ForeignKind { 202 enum ForeignKind {
195 JS, 203 JS,
196 JS_BUILTIN, 204 JS_BUILTIN,
197 JS_EMBEDDED_GLOBAL, 205 JS_EMBEDDED_GLOBAL,
198 JS_INTERCEPTOR_CONSTANT, 206 JS_INTERCEPTOR_CONSTANT,
199 NONE, 207 NONE,
200 } 208 }
(...skipping 109 matching lines...) Expand 10 before | Expand all | Expand 10 after
310 /// Returns the [LoopClosureScope] for the loop [node] in [closureClassMaps]. 318 /// Returns the [LoopClosureScope] for the loop [node] in [closureClassMaps].
311 LoopClosureScope getLoopClosureScope( 319 LoopClosureScope getLoopClosureScope(
312 ClosureDataLookup closureLookup, ir.TreeNode node); 320 ClosureDataLookup closureLookup, ir.TreeNode node);
313 } 321 }
314 322
315 /// Comparator for the canonical order or named arguments. 323 /// Comparator for the canonical order or named arguments.
316 // TODO(johnniwinther): Remove this when named parameters are sorted in dill. 324 // TODO(johnniwinther): Remove this when named parameters are sorted in dill.
317 int namedOrdering(ir.VariableDeclaration a, ir.VariableDeclaration b) { 325 int namedOrdering(ir.VariableDeclaration a, ir.VariableDeclaration b) {
318 return a.name.compareTo(b.name); 326 return a.name.compareTo(b.name);
319 } 327 }
OLDNEW
« no previous file with comments | « pkg/compiler/lib/src/js_model/elements.dart ('k') | pkg/compiler/lib/src/kernel/element_map_impl.dart » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698