Index: lib/compiler/implementation/lib/io.dart |
diff --git a/lib/compiler/implementation/lib/io.dart b/lib/compiler/implementation/lib/io.dart |
index 8d544b238cbf8285a84f6178114a03f001a426e0..f07ff84025df7cad8b81ed47ff4444c531fb1c43 100644 |
--- a/lib/compiler/implementation/lib/io.dart |
+++ b/lib/compiler/implementation/lib/io.dart |
@@ -80,7 +80,7 @@ class OSError { |
/** Converts an OSError object to a string representation. */ |
String toString() { |
- throw UnsupportedOperationException('OSError.toString'); |
+ throw new StateError('OSError.toString'); |
floitsch
2012/10/23 12:50:32
"Unsupported: OSError.toString", or (better)
new S
Lasse Reichstein Nielsen
2012/10/24 12:32:15
Now throws new UnsupportedError.
|
} |
/** |
@@ -97,52 +97,52 @@ class OSError { |
} |
List _ensureFastAndSerializableBuffer(List buffer, int offset, int bytes) { |
- throw new UnsupportedOperationException('_ensureFastAndSerializableBuffer'); |
+ throw new StateError('_ensureFastAndSerializableBuffer'); |
} |
class _File { |
factory _File(arg) { |
- throw new UnsupportedOperationException('new File($arg)'); |
+ throw new StateError('new File($arg)'); |
} |
factory _File.fromPath(arg) { |
- throw new UnsupportedOperationException('new File.fromPath($arg)'); |
+ throw new StateError('new File.fromPath($arg)'); |
} |
} |
class _Platform { |
static int get numberOfProcessors { |
- throw new UnsupportedOperationException('_Platform.numberOfProcessors'); |
+ throw new StateError('_Platform.numberOfProcessors'); |
} |
static String get pathSeparator { |
- throw new UnsupportedOperationException('_Platform.pathSeparator'); |
+ throw new StateError('_Platform.pathSeparator'); |
} |
static String get operatingSystem { |
- throw new UnsupportedOperationException('_Platform.operatingSystem'); |
+ throw new StateError('_Platform.operatingSystem'); |
} |
static String get localHostname { |
- throw new UnsupportedOperationException('_Platform.localHostname'); |
+ throw new StateError('_Platform.localHostname'); |
} |
static Map<String, String> get environment { |
- throw new UnsupportedOperationException('_Platform.environment'); |
+ throw new StateError('_Platform.environment'); |
} |
} |
class _Directory { |
factory _Directory(arg) { |
- throw new UnsupportedOperationException('new Directory($arg)'); |
+ throw new StateError('new Directory($arg)'); |
} |
factory _Directory.fromPath(arg) { |
- throw new UnsupportedOperationException('new Directory.fromPath($arg)'); |
+ throw new StateError('new Directory.fromPath($arg)'); |
} |
factory _Directory.current() { |
- throw new UnsupportedOperationException('new Directory.current()'); |
+ throw new StateError('new Directory.current()'); |
} |
} |
@@ -150,7 +150,7 @@ class _DirectoryLister { |
} |
void _exit(int exitCode) { |
- throw new UnsupportedOperationException("exit($exitCode)"); |
+ throw new StateError("exit($exitCode)"); |
} |
class _Process { |
@@ -158,50 +158,50 @@ class _Process { |
List<String> arguments, |
[ProcessOptions options]) { |
var msg = 'Process.start($executable, $arguments, $options)'; |
- throw new UnsupportedOperationException(msg); |
+ throw new StateError(msg); |
} |
static Future<ProcessResult> run(String executable, |
List<String> arguments, |
[ProcessOptions options]) { |
var msg = 'Process.run($executable, $arguments, $options)'; |
- throw new UnsupportedOperationException(msg); |
+ throw new StateError(msg); |
} |
} |
class _ServerSocket { |
factory _ServerSocket(String bindAddress, int port, int backlog) { |
- throw new UnsupportedOperationException( |
+ throw new StateError( |
'new ServerSocket($bindAddress, $port, $backlog)'); |
} |
} |
class _Socket { |
factory _Socket(String host, int port) { |
- throw new UnsupportedOperationException('new Socket($host, $port)'); |
+ throw new StateError('new Socket($host, $port)'); |
} |
} |
class _EventHandler { |
factory _EventHandler() { |
- throw new UnsupportedOperationException('new _EventHandler()'); |
+ throw new StateError('new _EventHandler()'); |
} |
static void _start() { |
- throw new UnsupportedOperationException('_EventHandler._start()'); |
+ throw new StateError('_EventHandler._start()'); |
} |
static _sendData(int id, ReceivePort receivePort, int data) { |
var msg = '_EventHandler._sendData($id, $receivePort, $data)'; |
- throw new UnsupportedOperationException(msg); |
+ throw new StateError(msg); |
} |
static _EventHandler get _eventHandler { |
- throw new UnsupportedOperationException('_EventHandler._eventhandler'); |
+ throw new StateError('_EventHandler._eventhandler'); |
} |
static void set _eventHandler(_EventHandler e) { |
- throw new UnsupportedOperationException('_EventHandler._eventhandler = $e'); |
+ throw new StateError('_EventHandler._eventhandler = $e'); |
} |
} |