Chromium Code Reviews

Unified Diff: lib/src/util/io.dart

Issue 1290763003: Drop support for old SDK and shelf versions. (Closed) Base URL: git@github.com:dart-lang/test@master
Patch Set: Code review changes Created 5 years, 4 months ago
Use n/p to move between diff chunks; N/P to move between comments.
Jump to:
View side-by-side diff with in-line comments
« no previous file with comments | « lib/src/util/dart.dart ('k') | lib/src/util/isolate_wrapper.dart » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: lib/src/util/io.dart
diff --git a/lib/src/util/io.dart b/lib/src/util/io.dart
index a2b23d8f61e2885017da29afa36bcccb86e3721d..ceb8da6c9992ecc06e79cb933e99eab5d0b4805a 100644
--- a/lib/src/util/io.dart
+++ b/lib/src/util/io.dart
@@ -24,16 +24,7 @@ const _newline = 0xA;
const _carriageReturn = 0xD;
/// The root directory of the Dart SDK.
-final String sdkDir = (() {
- // TODO(kevmoo): work-around for accessing the SDK root dartbug.com/16994
- //
- // Don't resolve symlinks on Windows because of issue 133. Once the TODO above
- // is resolved, we won't have to do explicit symlink resolution anyway.
- var path = Platform.isWindows
- ? Platform.executable
- : new File(Platform.executable).resolveSymbolicLinksSync();
- return p.dirname(p.dirname(path));
-})();
+final String sdkDir = p.dirname(p.dirname(Platform.resolvedExecutable));
/// The version of the Dart SDK currently in use.
final Version _sdkVersion = new Version.parse(
@@ -68,22 +59,6 @@ String libDir({String packageRoot}) {
return p.dirname(p.dirname(p.dirname(pathToIo)));
}
-/// Returns whether the current Dart version has a fix for issue 23084.
-final bool supportsPubServe = ((){
- // This isn't 100% accurate, since issue 23084 wasn't fixed in early 1.10 dev
- // releases, but it's unlikely anyone will be using them.
- // TODO(nweiz): remove this when we no longer support older Dart versions.
- return new VersionConstraint.parse('>=1.9.2 <2.0.0').allows(_sdkVersion);
-})();
-
-/// Returns whether the current Dart version supports running isolates in
-/// checked mode.
-final bool supportsIsolateCheckedMode = (() {
- // TODO(nweiz): remove this when we no longer support older Dart versions.
- return new VersionConstraint.parse('>=1.11.0-dev.5.0 <2.0.0')
- .allows(_sdkVersion);
-})();
-
// TODO(nweiz): Make this check [stdioType] once that works within "pub run".
/// Whether "special" strings such as Unicode characters or color escapes are
/// safe to use.
« no previous file with comments | « lib/src/util/dart.dart ('k') | lib/src/util/isolate_wrapper.dart » ('j') | no next file with comments »

Powered by Google App Engine