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

Unified Diff: pkg/compiler/lib/src/kernel/element_map_impl.dart

Issue 2961253005: Added for-loop variable tracking and regular closures/initializers captured variable tracking. (Closed)
Patch Set: . Created 3 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 side-by-side diff with in-line comments
Download patch
Index: pkg/compiler/lib/src/kernel/element_map_impl.dart
diff --git a/pkg/compiler/lib/src/kernel/element_map_impl.dart b/pkg/compiler/lib/src/kernel/element_map_impl.dart
index fc663e4fd02d2c885c3808680ae67f60ed7ae59d..5c2f8a50336368abbf3c233b47d189a6e0137921 100644
--- a/pkg/compiler/lib/src/kernel/element_map_impl.dart
+++ b/pkg/compiler/lib/src/kernel/element_map_impl.dart
@@ -774,6 +774,9 @@ class KernelToElementMapImpl extends KernelToElementMapForImpactImpl
ir.Class getKernelClass(KClass entity) => _classEnvs[entity.classIndex].cls;
+ ir.Member getKernelMember(KMember entity) =>
+ _memberList[entity.memberIndex].node;
+
bool hasConstantFieldInitializer(covariant KField field) {
_FieldData data = _memberList[field.memberIndex];
return getFieldConstantValue(data.node) != null;
@@ -1830,7 +1833,10 @@ class JsKernelToElementMap extends KernelToElementMapBase
@override
Local getLocalFunction(ir.TreeNode node) {
- throw new UnsupportedError("JsKernelToElementMap.getLocalFunction");
+ // TODO(efortuna, johnniwinther): This function should not be called once
+ // the K + J element situation has been properly sorted out. Ultimately this
+ // should throw.
+ return _elementMap.getLocalFunction(node);
}
@override

Powered by Google App Engine
This is Rietveld 408576698