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

Unified Diff: runtime/bin/common.dart

Issue 11275035: Introduce (private) ZLibFilter to dart:io. (Closed) Base URL: https://dart.googlecode.com/svn/branches/bleeding_edge/dart
Patch Set: Add InternalError class and LICENSE file. Created 8 years, 2 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 side-by-side diff with in-line comments
Download patch
Index: runtime/bin/common.dart
diff --git a/runtime/bin/common.dart b/runtime/bin/common.dart
index 33ce2a5dd9ef2e933205cefb6f3f973506935555..0455397e41092db060578105e05c764cd3dc30d1 100644
--- a/runtime/bin/common.dart
+++ b/runtime/bin/common.dart
@@ -54,6 +54,21 @@ class OSError {
final int errorCode;
}
+/**
+ * An [InternalError] can be thrown from native calls when an error occours
+ * inside native code.
+ */
+class InternalError {
+ const InternalError([String this.message = ""]);
+
+ String toString() {
+ if (message.isEmpty) return "InternalError";
+ return "InternalError: $message";
+ }
+
+ final String message;
+}
+
// Check if a List is a builtin VM List type. Returns true
// if the List is a builtin VM List type and false if it is

Powered by Google App Engine
This is Rietveld 408576698