commit | ba7921a84a9a92a27febd560f7c02b35b763178b | [log] [tgz] |
---|---|---|
author | Sam Rawlins <srawlins@google.com> | Tue Mar 29 04:51:30 2022 +0000 |
committer | Commit Bot <commit-bot@chromium.org> | Tue Mar 29 04:51:30 2022 +0000 |
tree | 9c912110ded69c20c3673dfde8f0336c219aec51 | |
parent | c895971315c7e86e55ab1ca3fc6ae044d3178883 [diff] |
Add dynamic return type when creating noSuchMethod Fixes https://github.com/dart-lang/sdk/issues/47142 Change-Id: I9fe504c91bff2486774285ce1b147eefefe7e2b0 Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/239125 Reviewed-by: Brian Wilkerson <brianwilkerson@google.com> Commit-Queue: Samuel Rawlins <srawlins@google.com>
diff --git a/pkg/analysis_server/lib/src/services/correction/dart/create_no_such_method.dart b/pkg/analysis_server/lib/src/services/correction/dart/create_no_such_method.dart index 8c93801..e885c0e 100644 --- a/pkg/analysis_server/lib/src/services/correction/dart/create_no_such_method.dart +++ b/pkg/analysis_server/lib/src/services/correction/dart/create_no_such_method.dart
@@ -33,8 +33,8 @@ builder.write('@override'); builder.write(eol); builder.write(prefix); - builder.write( - 'noSuchMethod(Invocation invocation) => super.noSuchMethod(invocation);'); + builder.write('dynamic noSuchMethod(Invocation invocation) => ' + 'super.noSuchMethod(invocation);'); builder.write(eol); }); });
diff --git a/pkg/analysis_server/test/src/services/correction/fix/create_no_such_method_test.dart b/pkg/analysis_server/test/src/services/correction/fix/create_no_such_method_test.dart index 00c6398..74de357 100644 --- a/pkg/analysis_server/test/src/services/correction/fix/create_no_such_method_test.dart +++ b/pkg/analysis_server/test/src/services/correction/fix/create_no_such_method_test.dart
@@ -40,7 +40,7 @@ existing() {} @override - noSuchMethod(Invocation invocation) => super.noSuchMethod(invocation); + dynamic noSuchMethod(Invocation invocation) => super.noSuchMethod(invocation); } '''); }