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

Unified Diff: pkg/analysis_server/lib/src/services/correction/util.dart

Issue 1147213005: Issue 23545. Replace unaccessible type parameters with 'dynamic'. (Closed) Base URL: git@github.com:dart-lang/sdk.git@master
Patch Set: Created 5 years, 7 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
« no previous file with comments | « no previous file | pkg/analysis_server/test/services/correction/fix_test.dart » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: pkg/analysis_server/lib/src/services/correction/util.dart
diff --git a/pkg/analysis_server/lib/src/services/correction/util.dart b/pkg/analysis_server/lib/src/services/correction/util.dart
index 9a2a8121b96761088939997cae3fb47825b826ca..c4082fa4765f599d1158f5dad493042ce6abf6ff 100644
--- a/pkg/analysis_server/lib/src/services/correction/util.dart
+++ b/pkg/analysis_server/lib/src/services/correction/util.dart
@@ -1030,6 +1030,10 @@ class CorrectionUtils {
*/
String getTypeSource(DartType type, Set<LibraryElement> librariesToImport) {
StringBuffer sb = new StringBuffer();
+ // type parameter
+ if (!_isTypeVisible(type)) {
+ return 'dynamic';
+ }
// just a Function, not FunctionTypeAliasElement
if (type is FunctionType && type.element is! FunctionTypeAliasElement) {
return "Function";
« no previous file with comments | « no previous file | pkg/analysis_server/test/services/correction/fix_test.dart » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698