mirror of
https://github.com/dart-lang/sdk
synced 2024-09-05 08:24:39 +00:00
[isolate/nnbd] fix nnbd errors in dart:isolate
Named optionals without defaults should be nullable (or we need default). Fixes: output: org-dartlang-sdk:///dart-sdk/lib/isolate/isolate.dart:340:15: Warning: Optional parameter 'packageRoot' doesn't have a default value and its type 'Uri' doesn't allow null. - 'Uri' is from 'dart:core'. Uri packageRoot, ^^^^^^^^^^^ org-dartlang-sdk:///dart-sdk/lib/isolate/isolate.dart:525:15: Warning: Optional parameter 'response' doesn't have a default value and its type 'Object' doesn't allow null. - 'Object' is from 'dart:core'. {Object response, int priority = immediate}); Change-Id: I040939a4c058275d5e083a85b84317d76f7a568b Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/135040 Reviewed-by: Siva Annamalai <asiva@google.com> Commit-Queue: Vijay Menon <vsm@google.com> Auto-Submit: Vijay Menon <vsm@google.com>
This commit is contained in:
parent
42e840c6ae
commit
b288fc61d6
|
@ -337,7 +337,7 @@ class Isolate {
|
|||
bool? checked,
|
||||
Map<String, String>? environment,
|
||||
@Deprecated('The packages/ dir is not supported in Dart 2')
|
||||
Uri packageRoot,
|
||||
Uri? packageRoot,
|
||||
Uri? packageConfig,
|
||||
bool automaticPackageResolution = false,
|
||||
@Since("2.3")
|
||||
|
@ -522,7 +522,7 @@ class Isolate {
|
|||
* are completed.
|
||||
*/
|
||||
external void ping(SendPort responsePort,
|
||||
{Object response, int priority = immediate});
|
||||
{Object? response, int priority = immediate});
|
||||
|
||||
/**
|
||||
* Requests that uncaught errors of the isolate are sent back to [port].
|
||||
|
|
Loading…
Reference in a new issue