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

Unified Diff: pkg/compiler/lib/src/types/flat_type_mask.dart

Issue 2613833005: Use entities in the TypeMask interface. (Closed)
Patch Set: dartfmt Created 3 years, 11 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/types/flat_type_mask.dart
diff --git a/pkg/compiler/lib/src/types/flat_type_mask.dart b/pkg/compiler/lib/src/types/flat_type_mask.dart
index c2027e2c5099ad990b889b44a4f8139ea51662c4..cbeba31a3e638009c350e4be7816517b0450e40b 100644
--- a/pkg/compiler/lib/src/types/flat_type_mask.dart
+++ b/pkg/compiler/lib/src/types/flat_type_mask.dart
@@ -512,7 +512,8 @@ class FlatTypeMask implements TypeMask {
* invoked on this type mask. [selector] is used to ensure library
* privacy is taken into account.
*/
- bool canHit(Element element, Selector selector, ClosedWorld closedWorld) {
+ bool canHit(
+ MemberElement element, Selector selector, ClosedWorld closedWorld) {
BackendClasses backendClasses = closedWorld.backendClasses;
assert(element.name == selector.name);
if (isEmpty) return false;
@@ -565,7 +566,8 @@ class FlatTypeMask implements TypeMask {
: (isSubclass ? ClassQuery.SUBCLASS : ClassQuery.SUBTYPE));
}
- Element locateSingleElement(Selector selector, ClosedWorld closedWorld) {
+ MemberElement locateSingleElement(
+ Selector selector, ClosedWorld closedWorld) {
if (isEmptyOrNull) return null;
Iterable<Element> targets = closedWorld.allFunctions.filter(selector, this);
if (targets.length != 1) return null;

Powered by Google App Engine
This is Rietveld 408576698