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

Unified Diff: lib/compiler/implementation/lib/js_helper.dart

Issue 10444086: Do not wrap the exception if we could not translate it to one of our internal exceptions. (Closed) Base URL: http://dart.googlecode.com/svn/branches/bleeding_edge/dart/
Patch Set: Created 8 years, 7 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 | « no previous file | tests/corelib/corelib.status » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: lib/compiler/implementation/lib/js_helper.dart
===================================================================
--- lib/compiler/implementation/lib/js_helper.dart (revision 8097)
+++ lib/compiler/implementation/lib/js_helper.dart (working copy)
@@ -837,9 +837,10 @@
}
}
- // Last resort: Create a completely generic exception object and use
- // the JS exception message as its argument.
- return new Exception(message);
+ // Just return the exception. We should not wrap it because in case
+ // the exception comes from the DOM, it is a JavaScript
+ // object backed by a native Dart class.
+ return ex;
}
/**
« no previous file with comments | « no previous file | tests/corelib/corelib.status » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698