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

Unified Diff: pkg/compiler/lib/src/inferrer/type_system.dart

Issue 2972653002: Use entities internally in MemberTypeInformation (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 side-by-side diff with in-line comments
Download patch
Index: pkg/compiler/lib/src/inferrer/type_system.dart
diff --git a/pkg/compiler/lib/src/inferrer/type_system.dart b/pkg/compiler/lib/src/inferrer/type_system.dart
index 03589b3bcfd093a069ac7b69596aa73f8eaa0ada..debbb4de1776847dd94a0c403f55d661ca7dae86 100644
--- a/pkg/compiler/lib/src/inferrer/type_system.dart
+++ b/pkg/compiler/lib/src/inferrer/type_system.dart
@@ -372,19 +372,25 @@ class TypeSystem {
return memberTypeInformations.putIfAbsent(member, () {
MemberTypeInformation typeInformation;
if (member.isField) {
- typeInformation = new FieldTypeInformation(member);
+ FieldElement field = member;
+ typeInformation = new FieldTypeInformation(field, field.type);
} else if (member.isGetter) {
- typeInformation = new GetterTypeInformation(member);
+ GetterElement getter = member;
+ typeInformation = new GetterTypeInformation(getter, getter.type);
} else if (member.isSetter) {
- typeInformation = new SetterTypeInformation(member);
+ SetterElement setter = member;
+ typeInformation = new SetterTypeInformation(setter);
} else if (member.isFunction) {
- typeInformation = new MethodTypeInformation(member);
+ MethodElement method = member;
+ typeInformation = new MethodTypeInformation(method, method.type);
} else {
ConstructorElement constructor = member;
if (constructor.isFactoryConstructor) {
- typeInformation = new FactoryConstructorTypeInformation(member);
+ typeInformation = new FactoryConstructorTypeInformation(
+ constructor, constructor.type);
} else {
- typeInformation = new GenerativeConstructorTypeInformation(member);
+ typeInformation =
+ new GenerativeConstructorTypeInformation(constructor);
}
}
_orderedTypeInformations.add(typeInformation);
« pkg/compiler/lib/src/dump_info.dart ('K') | « pkg/compiler/lib/src/inferrer/type_graph_nodes.dart ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698