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

Unified Diff: pkg/analyzer/test/generated/type_system_test.dart

Issue 2231273002: fix #26120, sideways casts no longer supported (Closed) Base URL: git@github.com:dart-lang/sdk.git@master
Patch Set: fix Created 4 years, 4 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/analyzer/test/generated/type_system_test.dart
diff --git a/pkg/analyzer/test/generated/type_system_test.dart b/pkg/analyzer/test/generated/type_system_test.dart
index c62f985f03312e563d3f03f4ee5f1bcc88c66f57..d7d72f87fe05264b02d0510950c1a1729b6bb0d6 100644
--- a/pkg/analyzer/test/generated/type_system_test.dart
+++ b/pkg/analyzer/test/generated/type_system_test.dart
@@ -164,6 +164,7 @@ class LeastUpperBoundTest extends LeastUpperBoundTestBase {
FunctionType expected = _functionType([objectType, numType, numType]);
_checkLeastUpperBound(type1, type2, expected);
}
+
void test_nestedNestedFunctionsLubInnermostParamTypes() {
FunctionType type1 = _functionType([
_functionType([
@@ -620,7 +621,11 @@ class StrongAssignabilityTest {
numType,
bottomType
];
- List<DartType> unrelated = <DartType>[intType, stringType, interfaceType,];
+ List<DartType> unrelated = <DartType>[
+ intType,
+ stringType,
+ interfaceType,
+ ];
_checkGroups(doubleType,
interassignable: interassignable, unrelated: unrelated);
@@ -750,7 +755,10 @@ class StrongAssignabilityTest {
doubleType,
bottomType
];
- List<DartType> unrelated = <DartType>[stringType, interfaceType,];
+ List<DartType> unrelated = <DartType>[
+ stringType,
+ interfaceType,
+ ];
_checkGroups(numType,
interassignable: interassignable, unrelated: unrelated);
@@ -780,10 +788,12 @@ class StrongAssignabilityTest {
void _checkCrossLattice(
DartType top, DartType left, DartType right, DartType bottom) {
- _checkGroups(top, interassignable: <DartType>[top, left, right, bottom]);
- _checkGroups(left, interassignable: <DartType>[top, left, right, bottom]);
- _checkGroups(right, interassignable: <DartType>[top, left, right, bottom]);
- _checkGroups(bottom, interassignable: <DartType>[top, left, right, bottom]);
+ _checkGroups(top, interassignable: [top, left, right, bottom]);
+ _checkGroups(left,
+ interassignable: [top, left, bottom], unrelated: [right]);
+ _checkGroups(right,
+ interassignable: [top, right, bottom], unrelated: [left]);
+ _checkGroups(bottom, interassignable: [top, left, right, bottom]);
}
void _checkEquivalent(DartType type1, DartType type2) {

Powered by Google App Engine
This is Rietveld 408576698