Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(538)

Side by Side Diff: pkg/analyzer/lib/file_system/physical_file_system.dart

Issue 1847633002: Fix more strong mode errors in analyzer (Closed) Base URL: https://github.com/dart-lang/sdk.git@master
Patch Set: Fix copied comment Created 4 years, 8 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch
OLDNEW
1 // Copyright (c) 2014, the Dart project authors. Please see the AUTHORS file 1 // Copyright (c) 2014, the Dart project authors. Please see the AUTHORS file
2 // for details. All rights reserved. Use of this source code is governed by a 2 // for details. All rights reserved. Use of this source code is governed by a
3 // BSD-style license that can be found in the LICENSE file. 3 // BSD-style license that can be found in the LICENSE file.
4 4
5 library analyzer.file_system.physical_file_system; 5 library analyzer.file_system.physical_file_system;
6 6
7 import 'dart:async'; 7 import 'dart:async';
8 import 'dart:core' hide Resource; 8 import 'dart:core' hide Resource;
9 import 'dart:io' as io; 9 import 'dart:io' as io;
10 10
(...skipping 114 matching lines...) Expand 10 before | Expand all | Expand 10 after
125 String readAsStringSync() { 125 String readAsStringSync() {
126 try { 126 try {
127 io.File file = _entry as io.File; 127 io.File file = _entry as io.File;
128 return FileBasedSource.fileReadMode(file.readAsStringSync()); 128 return FileBasedSource.fileReadMode(file.readAsStringSync());
129 } on io.FileSystemException catch (exception) { 129 } on io.FileSystemException catch (exception) {
130 throw new FileSystemException(exception.path, exception.message); 130 throw new FileSystemException(exception.path, exception.message);
131 } 131 }
132 } 132 }
133 133
134 @override 134 @override
135 Resource renameSync(String newPath) { 135 File renameSync(String newPath) {
136 try { 136 try {
137 io.File file = _entry as io.File; 137 io.File file = _entry as io.File;
138 io.File newFile = file.renameSync(newPath); 138 io.File newFile = file.renameSync(newPath);
139 return new _PhysicalFile(newFile); 139 return new _PhysicalFile(newFile);
140 } on io.FileSystemException catch (exception) { 140 } on io.FileSystemException catch (exception) {
141 throw new FileSystemException(exception.path, exception.message); 141 throw new FileSystemException(exception.path, exception.message);
142 } 142 }
143 } 143 }
144 144
145 @override 145 @override
(...skipping 105 matching lines...) Expand 10 before | Expand all | Expand 10 after
251 bool operator ==(other) { 251 bool operator ==(other) {
252 if (runtimeType != other.runtimeType) { 252 if (runtimeType != other.runtimeType) {
253 return false; 253 return false;
254 } 254 }
255 return path == other.path; 255 return path == other.path;
256 } 256 }
257 257
258 @override 258 @override
259 String toString() => path; 259 String toString() => path;
260 } 260 }
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698