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

Unified Diff: sdk/lib/_internal/compiler/implementation/js_backend/runtime_types.dart

Issue 12598003: Support type variables as expressions. (Closed) Base URL: https://dart.googlecode.com/svn/branches/bleeding_edge/dart
Patch Set: Update illegal_invocation_test and status. Created 7 years, 9 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: sdk/lib/_internal/compiler/implementation/js_backend/runtime_types.dart
diff --git a/sdk/lib/_internal/compiler/implementation/js_backend/runtime_types.dart b/sdk/lib/_internal/compiler/implementation/js_backend/runtime_types.dart
index 266d5bb8f72a607d880cc604208c6cf95c09c136..e38cc6e4ec5cdfb227c73e01e26746629a831e3e 100644
--- a/sdk/lib/_internal/compiler/implementation/js_backend/runtime_types.dart
+++ b/sdk/lib/_internal/compiler/implementation/js_backend/runtime_types.dart
@@ -229,12 +229,12 @@ class RuntimeTypeInformation {
return false;
}
- static int getTypeVariableIndex(TypeVariableType variable) {
- ClassElement classElement = variable.element.getEnclosingClass();
+ static int getTypeVariableIndex(TypeVariableElement variable) {
+ ClassElement classElement = variable.getEnclosingClass();
Link<DartType> variables = classElement.typeVariables;
for (int index = 0; !variables.isEmpty;
index++, variables = variables.tail) {
- if (variables.head == variable) return index;
+ if (variables.head.element == variable) return index;
}
}
}

Powered by Google App Engine
This is Rietveld 408576698