Attention is currently required from: Nate Bosch.
Lasse R.H. Nielsen would like Nate Bosch to review this change.
Update documentation in dart:core.
Fix null safety issues and tweak documentation where it can be improved.
Change-Id: Ia8cc20274ae151c454662bf5f137913787365a64
---
M sdk/lib/core/annotations.dart
M sdk/lib/core/bigint.dart
M sdk/lib/core/bool.dart
M sdk/lib/core/comparable.dart
M sdk/lib/core/core.dart
M sdk/lib/core/date_time.dart
M sdk/lib/core/double.dart
M sdk/lib/core/duration.dart
M sdk/lib/core/errors.dart
M sdk/lib/core/exceptions.dart
M sdk/lib/core/expando.dart
M sdk/lib/core/function.dart
M sdk/lib/core/identical.dart
M sdk/lib/core/int.dart
M sdk/lib/core/invocation.dart
M sdk/lib/core/iterable.dart
M sdk/lib/core/iterator.dart
M sdk/lib/core/list.dart
M sdk/lib/core/map.dart
M sdk/lib/core/null.dart
M sdk/lib/core/num.dart
M sdk/lib/core/object.dart
M sdk/lib/core/pattern.dart
M sdk/lib/core/regexp.dart
M sdk/lib/core/set.dart
M sdk/lib/core/sink.dart
M sdk/lib/core/stacktrace.dart
M sdk/lib/core/stopwatch.dart
M sdk/lib/core/string.dart
M sdk/lib/core/string_buffer.dart
M sdk/lib/core/string_sink.dart
M sdk/lib/core/symbol.dart
M sdk/lib/core/type.dart
M sdk/lib/core/uri.dart
34 files changed, 5,933 insertions(+), 6,788 deletions(-)
To view, visit change 177960. To unsubscribe, or for help writing mail filters, visit settings.
Attention is currently required from: Nate Bosch.
1 comment:
Patchset:
First part of null-safety checking platform library docs.
Decided to convert them to /// on the way.
To view, visit change 177960. To unsubscribe, or for help writing mail filters, visit settings.
Attention is currently required from: Nate Bosch.
go/dart-cbuild result: SUCCESS
Details: https://goto.google.com/dart-cbuild/find/198950cc0b3802d29d4c372e383c7d6c588a6772
Attention is currently required from: Nate Bosch.
2 comments:
Patchset:
Will have to update some golden files. As usual.
File sdk/lib/core/errors.dart:
Patch Set #1, Line 439: @deprecated
Will remove this @deprecated from this CL and add it later.
To view, visit change 177960. To unsubscribe, or for help writing mail filters, visit settings.
Attention is currently required from: Lasse R.H. Nielsen.
4 comments:
Patchset:
I started to dig through this, but I think the size of the diff is masking the more meaningful changes.
Can we first change from `/**` to `///` and commit that without text changes, and then take a look at the text changes?
If we open a separate CL to switch to `///` then rebase onto that but keep these file versions it should lead to an easier diff to read, and we can trivially approve the CL change switches comment styles.
File sdk/lib/core/annotations.dart:
Patch Set #1, Line 13: /// that they should change their code, even if it is currently still working
This sentence reads strangely to me.
Is this missing the word "in"?
"of a feature that they should change in their code"?
Would it make sense also to replace "change" with "stop using"?
Patch Set #1, Line 39: /// - the code imports a deprecated library.
[nit] These are formatted as sentences with a period at the end - should they start with a capital letter?
Patch Set #1, Line 43: /// - the code dynamically uses a member of an object with a statically known
Is this something that any of our tools do? I don't think it's worth mentioning if it's not something that happens in practice.
To view, visit change 177960. To unsubscribe, or for help writing mail filters, visit settings.
Attention is currently required from: Nate Bosch.
3 comments:
File sdk/lib/core/annotations.dart:
Patch Set #1, Line 13: /// that they should change their code, even if it is currently still working
This sentence reads strangely to me. […]
I think the phrasing is correct, can't vouch for the punctuation.
People, who are using a feature, should change their code.
But rewriting to say "stop using the feature" instead of "change their code" is more direct. Like it.
Patch Set #1, Line 39: /// - the code imports a deprecated library.
[nit] These are formatted as sentences with a period at the end - should they start with a capital l […]
I'd say no. They are not complete sentences, but are alternative completions of the previous sentence part.
Patch Set #1, Line 43: /// - the code dynamically uses a member of an object with a statically known
Is this something that any of our tools do? I don't think it's worth mentioning if it's not somethin […]
I'm not entirely sure what this paragraph means. I don't think it means `dynamic` invocation, probably just a normal interface invocation where the interface has deprecated the feature.
I'll try to rephrase it.
To view, visit change 177960. To unsubscribe, or for help writing mail filters, visit settings.
Attention is currently required from: Nate Bosch.
2 comments:
Patchset:
You can now compare Patchset 2 (triple-slash and formatting only) to Patchset 3 (actual changes).
File sdk/lib/core/core.dart:
Patch Set #3, Line 76: /// villains.addAll(['Joker', 'Lex Luthor', 'Voldemort']);
This one is highly embarrassing!
To view, visit change 177960. To unsubscribe, or for help writing mail filters, visit settings.
Attention is currently required from: Nate Bosch.
go/dart-cbuild result: SUCCESS
Details: https://goto.google.com/dart-cbuild/find/00bd6df8b89826fed7b04de86da001b50c92eeac
Attention is currently required from: Nate Bosch.
1 comment:
Patchset:
PTAL
To view, visit change 177960. To unsubscribe, or for help writing mail filters, visit settings.
Attention is currently required from: Nate Bosch.
go/dart-cbuild result: SUCCESS
Details: https://goto.google.com/dart-cbuild/find/2df58ef8bf123e149c3b645257a1f17e0283270b
Attention is currently required from: Lasse R.H. Nielsen.
Patch set 6:Code-Review +1
20 comments:
File sdk/lib/core/duration.dart:
Patch Set #3, Line 51: /// The number of microseconds per milliseconds as a readable constant.
[nit] millisecond should not be plural
Patch Set #3, Line 54: /// The number of milliseconds per second as a readable constant.
[nit] The "as a readable constant" reads as noise to me. Can we remove it?
Patch Set #3, Line 57: /// The number of seconds per minute as a readable constant.
[optional] The notion of context independence is described well in the class doc, do you see any value in also calling out that not every minute is exactly 60 seconds?
Maybe something like
/// The number of seconds per minute excluding leap seconds.
Patch Set #3, Line 63: /// The number of hours per day as a readable constant.
Is there any value in calling out DST changes?
/// The number of hours per day excluding days with a daylight savings change.
File sdk/lib/core/errors.dart:
Patch Set #3, Line 45: /// occurrence, but being an [Excpetion] has no other effect
typo - [Exception]
Patch Set #3, Line 102: /// Creates an assertion error with the provided [message].
Should we deprecate this?
Is there a valid use case for manually constructing an assertion error instead of using `assert`?
Patch Set #3, Line 141: /// Creates an error with [message] describing the problem.
how about
/// Creates an error with [message] describing the problem with a passed argument.
Patch Set #3, Line 437: /// No longer used in Dart 2 where it has become a compile-time error
Should this be deprecated?
Patch Set #3, Line 576: /// replaced by late varibles and [LateInitializationError].
typo - variables
Patch Set #3, Line 577: // TODO: Deprecate?
+1
File sdk/lib/core/exceptions.dart:
Patch Set #3, Line 168: // Should be removed, and division by zero should just throw an
We should either make this a TODO, file an issue, or remove it. As a comment without a TODO I don't think this is adding any value.
File sdk/lib/core/expando.dart:
Patch Set #3, Line 42: /// and cannot be `null`.
Do we need to say this explicitly when the argument type isn't nullable?
File sdk/lib/core/list.dart:
Patch Set #3, Line 64: /// List fixedLengthList = List(3);
[nit]
var fixedLengthList = List(3);
File sdk/lib/core/map.dart:
Patch Set #3, Line 97: /// The example below creates a new map from a list integers.
[nit] list of integers.
Patch Set #3, Line 121: factory Map.fromIterable(Iterable iterable,
Would it be worth mentioning for-loop elements in this doc, or linking to somewhere that does?
I don't think that it makes sense to deprecate this constructor entirely, but in every case I've seen I think the map literal is more readable, and type inference works a lot better. I think most users would be well served by being introduced to that concept if they want to use this constructor.
Patch Set #3, Line 186: /// Whether this map contains the given [value].
[nit] I think that methods can keep the `Returns` phrasing is better for methods.
File sdk/lib/core/num.dart:
Patch Set #3, Line 224: /// Minus one, zero or plus one depending on the sign and
How about "Negative" in place of "Minus" and "Positive" in place of "Plus" here and the paragraph below?
File sdk/lib/core/object.dart:
Patch Set #3, Line 78: /// Objects that are not equal, are allowed to have the same hash code,
I don't think this added comma is necessary. The paragraph might read more nicely if the first part was broken into a separate sentence?
/// Objects that are not equal are allowed to have the same hash code.
/// It is even technically allowed that all instances have the same hash code,
File sdk/lib/core/string.dart:
Patch Set #3, Line 26: /// '''A
Why is this one indented and the others aren't?
File sdk/lib/core/uri.dart:
Patch Set #3, Line 483: /// Creats a file path from a file URI.
Typo in Creates
To view, visit change 177960. To unsubscribe, or for help writing mail filters, visit settings.
Attention is currently required from: Lasse R.H. Nielsen.
Patch set 8:Commit-Queue +2
Attention is currently required from: Lasse R.H. Nielsen.
CQ is trying the patch.
Note: The patchset #8 "Address comments." sent to CQ was uploaded after this CL was CR+1-ed.
Reviewer, please verify there is nothing unexpected https://dart-review.googlesource.com/c/177960/8
Bot data: {"action": "start", "triggered_at": "2021-01-12T12:18:28.0Z", "revision": "ff785edefbf5b18d4109bca507596df03bfc944d"}
commi...@chromium.org submitted this change.
Update documentation in dart:core.
Fix null safety issues and tweak documentation where it can be improved.
Change-Id: Ia8cc20274ae151c454662bf5f137913787365a64
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/177960
Commit-Queue: Lasse R.H. Nielsen <l...@google.com>
Reviewed-by: Nate Bosch <nbo...@google.com>
---
M pkg/front_end/testcases/extensions/annotations.dart.strong.expect
M pkg/front_end/testcases/extensions/annotations.dart.strong.transformed.expect
M pkg/front_end/testcases/general/DeltaBlue.dart.strong.expect
M pkg/front_end/testcases/general/DeltaBlue.dart.strong.transformed.expect
M pkg/front_end/testcases/general/annotation_on_enum_values.dart.strong.expect
M pkg/front_end/testcases/general/annotation_on_enum_values.dart.strong.transformed.expect
M pkg/front_end/testcases/general/annotation_top.dart.strong.expect
M pkg/front_end/testcases/general/annotation_top.dart.strong.transformed.expect
M pkg/front_end/testcases/general/annotation_variable_declaration.dart.strong.expect
M pkg/front_end/testcases/general/annotation_variable_declaration.dart.strong.transformed.expect
M pkg/front_end/testcases/general/bug33099.dart.strong.expect
M pkg/front_end/testcases/general/bug33099.dart.strong.transformed.expect
M pkg/front_end/testcases/general/constants/circularity.dart.strong.expect
M pkg/front_end/testcases/general/constants/circularity.dart.strong.transformed.expect
M pkg/front_end/testcases/general/constants/const_asserts.dart.strong.expect
M pkg/front_end/testcases/general/constants/const_asserts.dart.strong.transformed.expect
M pkg/front_end/testcases/general/constants/const_collections.dart.strong.expect
M pkg/front_end/testcases/general/constants/const_collections.dart.strong.transformed.expect
M pkg/front_end/testcases/general/constants/const_constructor_coverage.dart.strong.expect
M pkg/front_end/testcases/general/constants/const_constructor_coverage.dart.strong.transformed.expect
M pkg/front_end/testcases/general/constants/various.dart.strong.expect
M pkg/front_end/testcases/general/constants/various.dart.strong.transformed.expect
M pkg/front_end/testcases/general/constants/with_unevaluated_agnostic/const_asserts.dart.strong.expect
M pkg/front_end/testcases/general/constants/with_unevaluated_agnostic/const_asserts.dart.strong.transformed.expect
M pkg/front_end/testcases/general/constants/with_unevaluated_agnostic/various.dart.strong.expect
M pkg/front_end/testcases/general/constants/with_unevaluated_agnostic/various.dart.strong.transformed.expect
M pkg/front_end/testcases/general/constants/with_unevaluated_agnostic/various_2.dart.strong.expect
M pkg/front_end/testcases/general/constants/with_unevaluated_agnostic/various_2.dart.strong.transformed.expect
M pkg/front_end/testcases/general/constructor_const_inference.dart.strong.expect
M pkg/front_end/testcases/general/constructor_const_inference.dart.strong.transformed.expect
M pkg/front_end/testcases/general/duplicated_declarations.dart.strong.expect
M pkg/front_end/testcases/general/expressions.dart.strong.expect
M pkg/front_end/testcases/general/expressions.dart.strong.transformed.expect
M pkg/front_end/testcases/general/issue31767.dart.strong.expect
M pkg/front_end/testcases/general/issue31767.dart.strong.transformed.expect
M pkg/front_end/testcases/general/issue41070.dart.strong.expect
M pkg/front_end/testcases/general/issue41070.dart.strong.transformed.expect
M pkg/front_end/testcases/general/magic_const.dart.strong.expect
M pkg/front_end/testcases/general/magic_const.dart.strong.transformed.expect
M pkg/front_end/testcases/general/metadata_enum.dart.strong.expect
M pkg/front_end/testcases/general/metadata_enum.dart.strong.transformed.expect
M pkg/front_end/testcases/general/redirecting_factory_const_inference.dart.strong.expect
M pkg/front_end/testcases/general/redirecting_factory_const_inference.dart.strong.transformed.expect
M pkg/front_end/testcases/general/redirection_type_arguments.dart.strong.expect
M pkg/front_end/testcases/general/redirection_type_arguments.dart.strong.transformed.expect
M pkg/front_end/testcases/general/sdk_diagnostic.dart.outline.expect
M pkg/front_end/testcases/general/sdk_diagnostic.dart.strong.expect
M pkg/front_end/testcases/general/sdk_diagnostic.dart.strong.transformed.expect
M pkg/front_end/testcases/general/type_variable_uses.dart.strong.expect
M pkg/front_end/testcases/general/type_variable_uses.dart.strong.transformed.expect
M pkg/front_end/testcases/general/with_dependencies/issue43538/main.dart.strong.expect
M pkg/front_end/testcases/general/with_dependencies/issue43538/main.dart.strong.transformed.expect
M pkg/front_end/testcases/general_nnbd_opt_out/DeltaBlue.dart.weak.expect
M pkg/front_end/testcases/general_nnbd_opt_out/DeltaBlue.dart.weak.transformed.expect
M pkg/front_end/testcases/general_nnbd_opt_out/annotation_on_enum_values.dart.weak.expect
M pkg/front_end/testcases/general_nnbd_opt_out/annotation_on_enum_values.dart.weak.transformed.expect
M pkg/front_end/testcases/general_nnbd_opt_out/annotation_top.dart.weak.expect
M pkg/front_end/testcases/general_nnbd_opt_out/annotation_top.dart.weak.transformed.expect
M pkg/front_end/testcases/general_nnbd_opt_out/annotation_variable_declaration.dart.weak.expect
M pkg/front_end/testcases/general_nnbd_opt_out/annotation_variable_declaration.dart.weak.transformed.expect
M pkg/front_end/testcases/general_nnbd_opt_out/bug33099.dart.weak.expect
M pkg/front_end/testcases/general_nnbd_opt_out/bug33099.dart.weak.transformed.expect
M pkg/front_end/testcases/general_nnbd_opt_out/constructor_const_inference.dart.weak.expect
M pkg/front_end/testcases/general_nnbd_opt_out/constructor_const_inference.dart.weak.transformed.expect
M pkg/front_end/testcases/general_nnbd_opt_out/duplicated_declarations.dart.weak.expect
M pkg/front_end/testcases/general_nnbd_opt_out/expressions.dart.weak.expect
M pkg/front_end/testcases/general_nnbd_opt_out/expressions.dart.weak.transformed.expect
M pkg/front_end/testcases/general_nnbd_opt_out/magic_const.dart.weak.expect
M pkg/front_end/testcases/general_nnbd_opt_out/magic_const.dart.weak.transformed.expect
M pkg/front_end/testcases/general_nnbd_opt_out/metadata_enum.dart.weak.expect
M pkg/front_end/testcases/general_nnbd_opt_out/metadata_enum.dart.weak.transformed.expect
M pkg/front_end/testcases/general_nnbd_opt_out/redirecting_factory_const_inference.dart.weak.expect
M pkg/front_end/testcases/general_nnbd_opt_out/redirecting_factory_const_inference.dart.weak.transformed.expect
M pkg/front_end/testcases/general_nnbd_opt_out/redirection_type_arguments.dart.weak.expect
M pkg/front_end/testcases/general_nnbd_opt_out/redirection_type_arguments.dart.weak.transformed.expect
M pkg/front_end/testcases/general_nnbd_opt_out/sdk_diagnostic.dart.weak.expect
M pkg/front_end/testcases/general_nnbd_opt_out/sdk_diagnostic.dart.weak.transformed.expect
M pkg/front_end/testcases/general_nnbd_opt_out/type_variable_uses.dart.weak.expect
M pkg/front_end/testcases/general_nnbd_opt_out/type_variable_uses.dart.weak.transformed.expect
M pkg/front_end/testcases/inference/constructors_infer_from_arguments_const.dart.strong.expect
M pkg/front_end/testcases/inference/constructors_infer_from_arguments_const.dart.strong.transformed.expect
M pkg/front_end/testcases/inference/constructors_infer_from_arguments_const_with_upper_bound.dart.strong.expect
M pkg/front_end/testcases/inference/constructors_infer_from_arguments_const_with_upper_bound.dart.strong.transformed.expect
M pkg/front_end/testcases/inference/downwards_inference_annotations.dart.strong.expect
M pkg/front_end/testcases/inference/downwards_inference_annotations.dart.strong.transformed.expect
M pkg/front_end/testcases/inference/downwards_inference_annotations_class_members.dart.strong.expect
M pkg/front_end/testcases/inference/downwards_inference_annotations_class_members.dart.strong.transformed.expect
M pkg/front_end/testcases/inference/downwards_inference_annotations_for_loop_variable.dart.strong.expect
M pkg/front_end/testcases/inference/downwards_inference_annotations_for_loop_variable.dart.strong.transformed.expect
M pkg/front_end/testcases/inference/downwards_inference_annotations_locals.dart.strong.expect
M pkg/front_end/testcases/inference/downwards_inference_annotations_locals.dart.strong.transformed.expect
M pkg/front_end/testcases/inference/downwards_inference_annotations_locals_referring_to_locals.dart.strong.expect
M pkg/front_end/testcases/inference/downwards_inference_annotations_locals_referring_to_locals.dart.strong.transformed.expect
M pkg/front_end/testcases/inference/downwards_inference_annotations_parameter.dart.strong.expect
M pkg/front_end/testcases/inference/downwards_inference_annotations_parameter.dart.strong.transformed.expect
M pkg/front_end/testcases/inference/downwards_inference_annotations_parameter_local.dart.strong.expect
M pkg/front_end/testcases/inference/downwards_inference_annotations_parameter_local.dart.strong.transformed.expect
M pkg/front_end/testcases/inference/downwards_inference_annotations_type_variable_local.dart.strong.expect
M pkg/front_end/testcases/inference/downwards_inference_annotations_type_variable_local.dart.strong.transformed.expect
M pkg/front_end/testcases/inference/downwards_inference_annotations_typedef.dart.strong.expect
M pkg/front_end/testcases/inference/downwards_inference_annotations_typedef.dart.strong.transformed.expect
M pkg/front_end/testcases/inference/inferred_type_is_enum.dart.strong.expect
M pkg/front_end/testcases/inference/inferred_type_is_enum.dart.strong.transformed.expect
M pkg/front_end/testcases/inference/inferred_type_is_enum_values.dart.strong.expect
M pkg/front_end/testcases/inference/inferred_type_is_enum_values.dart.strong.transformed.expect
M pkg/front_end/testcases/inference_new/const_invocation.dart.strong.expect
M pkg/front_end/testcases/inference_new/const_invocation.dart.strong.transformed.expect
M pkg/front_end/testcases/inference_new/switch.dart.strong.expect
M pkg/front_end/testcases/inference_new/switch.dart.strong.transformed.expect
M pkg/front_end/testcases/late_lowering/late_annotations.dart.strong.expect
M pkg/front_end/testcases/late_lowering/late_annotations.dart.strong.transformed.expect
M pkg/front_end/testcases/late_lowering/late_annotations.dart.weak.expect
M pkg/front_end/testcases/late_lowering/late_annotations.dart.weak.transformed.expect
M pkg/front_end/testcases/nnbd/assignability_error_messages.dart.strong.expect
M pkg/front_end/testcases/nnbd/assignability_error_messages.dart.strong.transformed.expect
M pkg/front_end/testcases/nnbd/assignability_error_messages.dart.weak.expect
M pkg/front_end/testcases/nnbd/assignability_error_messages.dart.weak.transformed.expect
M pkg/front_end/testcases/nnbd/constant_null_check.dart.strong.expect
M pkg/front_end/testcases/nnbd/constant_null_check.dart.strong.transformed.expect
M pkg/front_end/testcases/nnbd/constant_null_check.dart.weak.expect
M pkg/front_end/testcases/nnbd/constant_null_check.dart.weak.transformed.expect
M pkg/front_end/testcases/nnbd/constant_null_is.dart.strong.expect
M pkg/front_end/testcases/nnbd/constant_null_is.dart.strong.transformed.expect
M pkg/front_end/testcases/nnbd/constant_null_is.dart.weak.expect
M pkg/front_end/testcases/nnbd/constant_null_is.dart.weak.transformed.expect
M pkg/front_end/testcases/nnbd/constants.dart.strong.expect
M pkg/front_end/testcases/nnbd/constants.dart.strong.transformed.expect
M pkg/front_end/testcases/nnbd/constants.dart.weak.expect
M pkg/front_end/testcases/nnbd/constants.dart.weak.transformed.expect
M pkg/front_end/testcases/nnbd/external_fields.dart.strong.expect
M pkg/front_end/testcases/nnbd/external_fields.dart.strong.transformed.expect
M pkg/front_end/testcases/nnbd/external_fields.dart.weak.expect
M pkg/front_end/testcases/nnbd/external_fields.dart.weak.transformed.expect
M pkg/front_end/testcases/nnbd/nullable_access.dart.strong.expect
M pkg/front_end/testcases/nnbd/nullable_access.dart.strong.transformed.expect
M pkg/front_end/testcases/nnbd/nullable_access.dart.weak.expect
M pkg/front_end/testcases/nnbd/nullable_access.dart.weak.transformed.expect
M pkg/front_end/testcases/nnbd/potentially_constant_type_as.dart.strong.expect
M pkg/front_end/testcases/nnbd/potentially_constant_type_as.dart.strong.transformed.expect
M pkg/front_end/testcases/nnbd/potentially_constant_type_as.dart.weak.expect
M pkg/front_end/testcases/nnbd/potentially_constant_type_as.dart.weak.transformed.expect
M pkg/front_end/testcases/nnbd/potentially_constant_type_is.dart.strong.expect
M pkg/front_end/testcases/nnbd/potentially_constant_type_is.dart.strong.transformed.expect
M pkg/front_end/testcases/nnbd/potentially_constant_type_is.dart.weak.expect
M pkg/front_end/testcases/nnbd/potentially_constant_type_is.dart.weak.transformed.expect
M pkg/front_end/testcases/nnbd/return_null.dart.strong.expect
M pkg/front_end/testcases/nnbd/return_null.dart.strong.transformed.expect
M pkg/front_end/testcases/nnbd/return_null.dart.weak.expect
M pkg/front_end/testcases/nnbd/return_null.dart.weak.transformed.expect
M pkg/front_end/testcases/nnbd/switch_nullable_enum.dart.strong.expect
M pkg/front_end/testcases/nnbd/switch_nullable_enum.dart.strong.transformed.expect
M pkg/front_end/testcases/nnbd/switch_nullable_enum.dart.weak.expect
M pkg/front_end/testcases/nnbd/switch_nullable_enum.dart.weak.transformed.expect
M pkg/front_end/testcases/nnbd/switch_redesign_types.dart.strong.expect
M pkg/front_end/testcases/nnbd/switch_redesign_types.dart.strong.transformed.expect
M pkg/front_end/testcases/nnbd/switch_redesign_types.dart.weak.expect
M pkg/front_end/testcases/nnbd/switch_redesign_types.dart.weak.transformed.expect
M pkg/front_end/testcases/nnbd_mixed/constant_null_is.dart.weak.expect
M pkg/front_end/testcases/nnbd_mixed/constant_null_is.dart.weak.transformed.expect
M pkg/front_end/testcases/nnbd_mixed/constants.dart.weak.expect
M pkg/front_end/testcases/nnbd_mixed/constants.dart.weak.transformed.expect
M pkg/front_end/testcases/nnbd_mixed/literal_from_opt_in.dart.weak.expect
M pkg/front_end/testcases/nnbd_mixed/literal_from_opt_in.dart.weak.transformed.expect
M pkg/front_end/testcases/nnbd_mixed/object_bound_factory/main.dart.weak.expect
M pkg/front_end/testcases/nnbd_mixed/object_bound_factory/main.dart.weak.transformed.expect
M pkg/front_end/testcases/nnbd_mixed/object_bound_redirecting_factory/main.dart.weak.expect
M pkg/front_end/testcases/nnbd_mixed/object_bound_redirecting_factory/main.dart.weak.transformed.expect
M pkg/front_end/testcases/nnbd_mixed/unsound_checks.dart.weak.expect
M pkg/front_end/testcases/nnbd_mixed/unsound_checks.dart.weak.transformed.expect
M pkg/front_end/testcases/rasta/enum.dart.strong.expect
M pkg/front_end/testcases/rasta/enum.dart.strong.transformed.expect
M pkg/front_end/testcases/rasta/issue_000044.dart.strong.expect
M pkg/front_end/testcases/rasta/issue_000044.dart.strong.transformed.expect
M pkg/front_end/testcases/rasta/issue_000070.dart.strong.expect
M pkg/front_end/testcases/rasta/issue_000070.dart.strong.transformed.expect
M pkg/front_end/testcases/regress/issue_34403.dart.strong.expect
M pkg/front_end/testcases/regress/issue_34403.dart.strong.transformed.expect
M pkg/front_end/testcases/static_field_lowering/enum.dart.weak.expect
M pkg/front_end/testcases/static_field_lowering/enum.dart.weak.transformed.expect
213 files changed, 6,137 insertions(+), 6,971 deletions(-)
go/dart-cbuild result: SUCCESS
Details: https://goto.google.com/dart-cbuild/find/fe7efd5606e3fd93c10e7fc6f0536b0e331364b7
2 comments:
Commit Message:
Patch Set #9, Line 5: CommitDate: 2021-01-12 13:06:41 +0000
hello
Patchset:
hello
To view, visit change 177960. To unsubscribe, or for help writing mail filters, visit settings.
Alexander Thomas removed sajid sajid from this change.
To view, visit change 177960. To unsubscribe, or for help writing mail filters, visit settings.
18 comments:
File sdk/lib/core/duration.dart:
Patch Set #3, Line 51: /// The number of microseconds per milliseconds as a readable constant.
[nit] millisecond should not be plural
Done
Patch Set #3, Line 54: /// The number of milliseconds per second as a readable constant.
[nit] The "as a readable constant" reads as noise to me. […]
Done
Patch Set #3, Line 57: /// The number of seconds per minute as a readable constant.
[optional] The notion of context independence is described well in the class doc, do you see any val […]
Wrote:
/// Notice that some minutes of official clock time might
/// differ in length because of leap seconds.
/// The [Duration] and [DateTime] classes ignore leap seconds
/// and consider all minutes to have 60 seconds.
Patch Set #3, Line 63: /// The number of hours per day as a readable constant.
Is there any value in calling out DST changes? […]
/// Notice that some days may differe in length because
/// of time zone changes due to daylight saving.
/// The [Duration] class is time zone agnostic and
/// considers all days to have 24 hours.
File sdk/lib/core/errors.dart:
Patch Set #3, Line 102: /// Creates an assertion error with the provided [message].
Should we deprecate this? […]
I see no reason to deprecate it. You could potentially do something like:
assert(test || throw AssertionError("message"));
(Not so important after we added `message`, but it was useful before). I bet there are similar cases with people doing complicated tests in an assert and throwing their own errors.
Patch Set #3, Line 141: /// Creates an error with [message] describing the problem.
how about […]
Slightly too long. Dropped tha "passed" to fit on a line.
Patch Set #3, Line 437: /// No longer used in Dart 2 where it has become a compile-time error
Should this be deprecated?
Yes. But let's do that in a separate CL. It causes new warnings and errors that have to be fixed as well.
Patch Set #3, Line 576: /// replaced by late varibles and [LateInitializationError].
typo - variables
Done
Patch Set #3, Line 577: // TODO: Deprecate?
+1
Different CL.
File sdk/lib/core/exceptions.dart:
Patch Set #3, Line 168: // Should be removed, and division by zero should just throw an
We should either make this a TODO, file an issue, or remove it. […]
Added TODO(30743). Already had the issue.
File sdk/lib/core/expando.dart:
Patch Set #3, Line 42: /// and cannot be `null`.
Do we need to say this explicitly when the argument type isn't nullable?
I chose to write it with a "cannot" instead of "must not" to distinguish it from the other types, but include it because it states above that you cannot expand these types, including `null`, so it felt weird to not mention it here as well.
If it didn't work for you, then it probably won't for others, so I'll remove it.
File sdk/lib/core/list.dart:
Patch Set #3, Line 64: /// List fixedLengthList = List(3);
[nit] […]
Done
File sdk/lib/core/map.dart:
Patch Set #3, Line 121: factory Map.fromIterable(Iterable iterable,
Would it be worth mentioning for-loop elements in this doc, or linking to somewhere that does? […]
It's a very good idea. I've added a comment about it being equivalent to `<K,V>{for (var v in iterable) key(v): value(v)}` (except that the literal is actually better typed).
Patch Set #3, Line 186: /// Whether this map contains the given [value].
[nit] I think that methods can keep the `Returns` phrasing is better for methods.
I disagree on that.
We should either document a side-effect free function in terms of the computation ("Hashes the arguments") or the result ("The hash of the arguments").
If we choose the result, then add "Returns" is just going half-way back to describing behavior, without actually describing the computation.
The `Returns` provides no value at all to the reader, and I always get confused when I read it.
File sdk/lib/core/num.dart:
Patch Set #3, Line 224: /// Minus one, zero or plus one depending on the sign and
How about "Negative" in place of "Minus" and "Positive" in place of "Plus" here and the paragraph be […]
Done. I don't like the phrasing to begin with, but can't find a better one.
"Zero or unit value depending on the value of the number"?
File sdk/lib/core/object.dart:
Patch Set #3, Line 78: /// Objects that are not equal, are allowed to have the same hash code,
I don't think this added comma is necessary. […]
Agree on ending the sentence.
And apparently you don't need commas after relative clauses bound to a noun, so that too.
Done.
File sdk/lib/core/string.dart:
Patch Set #3, Line 26: /// '''A
Why is this one indented and the others aren't?
Reasons? Fixed.
File sdk/lib/core/uri.dart:
Patch Set #3, Line 483: /// Creats a file path from a file URI.
Typo in Creates
Done
To view, visit change 177960. To unsubscribe, or for help writing mail filters, visit settings.