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

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

Issue 11049023: [dart2js] Report an error if throw is used outside of catch expression without an argument. (Closed) Base URL: https://dart.googlecode.com/svn/branches/bleeding_edge/dart
Patch Set: 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
« no previous file with comments | « lib/compiler/implementation/ssa/builder.dart ('k') | tests/co19/co19-dart2dart.status » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: lib/compiler/implementation/warnings.dart
diff --git a/lib/compiler/implementation/warnings.dart b/lib/compiler/implementation/warnings.dart
index 3c0ec5300aa8bd1231f8a0cefca979b9b3e21b78..dee9526b72f8621565ce9e685ed213da7a3609fd 100644
--- a/lib/compiler/implementation/warnings.dart
+++ b/lib/compiler/implementation/warnings.dart
@@ -116,6 +116,9 @@ class MessageKind {
'cannot use modifiers in catch');
static const OPTIONAL_PARAMETER_IN_CATCH = const MessageKind(
'cannot use optional parameters in catch');
+ static const THROW_WITHOUT_EXPRESSION = const MessageKind(
+ 'cannot use re-throw outside of catch block (expression expected after '
+ '"throw")');
static const UNBOUND_LABEL = const MessageKind(
'cannot resolve label #{1}');
static const NO_BREAK_TARGET = const MessageKind(
« no previous file with comments | « lib/compiler/implementation/ssa/builder.dart ('k') | tests/co19/co19-dart2dart.status » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698