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

Unified Diff: sdk/lib/_internal/lib/js_helper.dart

Issue 18529003: Add stackTrace to Error object. (Closed) Base URL: https://dart.googlecode.com/svn/branches/bleeding_edge/dart
Patch Set: Address comments and add bug numbers to status files. Created 7 years, 6 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
« no previous file with comments | « sdk/lib/_internal/lib/core_patch.dart ('k') | sdk/lib/core/errors.dart » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: sdk/lib/_internal/lib/js_helper.dart
diff --git a/sdk/lib/_internal/lib/js_helper.dart b/sdk/lib/_internal/lib/js_helper.dart
index fadb9846d74a2e0f013707ccd60065748435b89e..453e1ac8b4dc1ba6018f8d79a616dc4b8802bbba 100644
--- a/sdk/lib/_internal/lib/js_helper.dart
+++ b/sdk/lib/_internal/lib/js_helper.dart
@@ -679,7 +679,7 @@ checkString(value) {
* object out of the wrapper again.
*/
wrapException(ex) {
- if (ex == null) ex = const NullThrownError();
+ if (ex == null) ex = new NullThrownError();
var wrapper = new DartError(ex);
if (JS('bool', '!!Error.captureStackTrace')) {
@@ -1023,7 +1023,7 @@ jsPropertyAccess(var jsObject, String property) {
* Called at the end of unaborted switch cases to get the singleton
* FallThroughError exception that will be thrown.
*/
-getFallThroughError() => const FallThroughErrorImplementation();
+getFallThroughError() => new FallThroughErrorImplementation();
/**
* Represents the type dynamic. The compiler treats this specially.
@@ -1439,8 +1439,8 @@ class CastErrorImplementation implements CastError {
String toString() => message;
}
-class FallThroughErrorImplementation implements FallThroughError {
- const FallThroughErrorImplementation();
+class FallThroughErrorImplementation extends FallThroughError {
+ FallThroughErrorImplementation();
String toString() => "Switch case fall-through.";
}
@@ -1478,7 +1478,7 @@ void throwCyclicInit(String staticName) {
/**
* Error thrown when a runtime error occurs.
*/
-class RuntimeError implements Error {
+class RuntimeError extends Error {
final message;
RuntimeError(this.message);
String toString() => "RuntimeError: $message";
« no previous file with comments | « sdk/lib/_internal/lib/core_patch.dart ('k') | sdk/lib/core/errors.dart » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698