mirror of
https://github.com/dart-lang/sdk
synced 2024-09-16 00:39:49 +00:00
5ae4448779
This is a breaking change. https://github.com/dart-lang/sdk/issues/40706 The dummy object returned if FileStat.stat() and FileStat.statSync() fail now contains Unix epoch timestamps instead of null for the accessed, changed, and modified getters. These timestamps are always non-null if the API succeeds and the timestamps are meaningless when the API fails and returns the FileSystemEntityType.notFound type. This change makes the timestamps always non-null, which avoids all legitimate accesses needing a needless null check when Dart becomes null safe. This change is consistent with the mode and size getters that are initialized to non-null dummy values when the API fail. The NNBD migration required making subtle changes to some dart:io semantics in order to provide a better API. This change backports one of these semantic changes to the unmigrated SDK so any issues can be discovered now instead of blocking the future SDK unfork. Change-Id: Iff6b34d04b60f4c9f4cf8d9dd0679f721d142ba4 Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/136585 Reviewed-by: Lasse R.H. Nielsen <lrn@google.com> |
||
---|---|---|
.. | ||
bin | ||
lib | ||
api_readme.md | ||
BUILD.gn |