mirror of
https://github.com/dart-lang/sdk
synced 2024-09-16 04:37:12 +00:00
Type RandomAccessFile in io_resource_info to avoid dynamic invocation of path
There's one only one path for creating a _FileResourceInfo which comes from RandomAccessFile. Type the `file` field to avoid a dynamic call to `.path`. Change-Id: Ia1041d5b221d0496af3dd177562263b31cdf4157 Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/259106 Reviewed-by: Leaf Petersen <leafp@google.com> Commit-Queue: Kallen Tu <kallentu@google.com>
This commit is contained in:
parent
822ae59aca
commit
af20d93e56
|
@ -39,7 +39,6 @@
|
|||
"Dynamic invocation of '[]='.": 1
|
||||
},
|
||||
"org-dartlang-sdk:///lib/io/io_resource_info.dart": {
|
||||
"Dynamic access of 'path'.": 1,
|
||||
"Dynamic access of 'dart.io::_path'.": 1,
|
||||
"Dynamic access of 'pid'.": 1,
|
||||
"Dynamic access of 'dart.io::_arguments'.": 1,
|
||||
|
|
|
@ -88,7 +88,7 @@ abstract class _ReadWriteResourceInfo extends _IOResourceInfo {
|
|||
class _FileResourceInfo extends _ReadWriteResourceInfo {
|
||||
static const String _type = 'OpenFile';
|
||||
|
||||
final file;
|
||||
final RandomAccessFile file;
|
||||
|
||||
static Map<int, _FileResourceInfo> openFiles = {};
|
||||
|
||||
|
|
Loading…
Reference in a new issue