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

Unified Diff: pkg/analyzer/test/src/summary/summary_common.dart

Issue 1807213005: Use GLB for function parameters when doing LUB in strong mode. (Closed) Base URL: https://github.com/dart-lang/sdk.git@master
Patch Set: Fix summary tests that are doing the right thing now. Created 4 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: pkg/analyzer/test/src/summary/summary_common.dart
diff --git a/pkg/analyzer/test/src/summary/summary_common.dart b/pkg/analyzer/test/src/summary/summary_common.dart
index ae3d8ec30a10a8d74e7f48564b66d0272e97eef8..9dc82a1dbc6b3c02f7c93a106d4406e6e3ccb946 100644
--- a/pkg/analyzer/test/src/summary/summary_common.dart
+++ b/pkg/analyzer/test/src/summary/summary_common.dart
@@ -6600,14 +6600,12 @@ void set f(value) {}''';
final v = f() ? /*<T>*/(T t) => 0 : /*<T>*/(T t) => 1;
bool f() => true;
''');
- // The inferred type of `v` is currently `(Object) -> int` due to
- // dartbug.com/25802. TODO(paulberry): fix this test when the bug is fixed.
EntityRef inferredType = getTypeRefForSlot(variable.inferredTypeSlot);
checkLinkedTypeRef(
inferredType.syntheticReturnType, 'dart:core', 'dart:core', 'int');
expect(inferredType.syntheticParams, hasLength(1));
- checkLinkedTypeRef(inferredType.syntheticParams[0].type, 'dart:core',
- 'dart:core', 'Object');
+ checkLinkedTypeRef(
+ inferredType.syntheticParams[0].type, null, null, '*bottom*');
}
test_syntheticFunctionType_genericClosure_inGenericFunction() {
@@ -6628,16 +6626,14 @@ void f<T, U>(bool b) {
final v = b ? /*<V>*/(T t, U u, V v) => 0 : /*<V>*/(T t, U u, V v) => 1;
}
''').localVariables[0];
- // The inferred type of `v` is currently `(T, U, Object) -> int` due to
- // dartbug.com/25802. TODO(paulberry): fix this test when the bug is fixed.
EntityRef inferredType = getTypeRefForSlot(variable.inferredTypeSlot);
checkLinkedTypeRef(
inferredType.syntheticReturnType, 'dart:core', 'dart:core', 'int');
expect(inferredType.syntheticParams, hasLength(3));
checkParamTypeRef(inferredType.syntheticParams[0].type, 2);
checkParamTypeRef(inferredType.syntheticParams[1].type, 1);
- checkLinkedTypeRef(inferredType.syntheticParams[2].type, 'dart:core',
- 'dart:core', 'Object');
+ checkLinkedTypeRef(
+ inferredType.syntheticParams[2].type, null, null, '*bottom*');
}
test_syntheticFunctionType_inGenericClass() {
« no previous file with comments | « pkg/analyzer/test/generated/type_system_test.dart ('k') | pkg/analyzer/test/src/task/strong/checker_test.dart » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698