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

Unified Diff: pkg/compiler/lib/src/resolution/send_structure.dart

Issue 1325843003: Add optional message to assert in Dart2js. (Closed) Base URL: https://github.com/dart-lang/sdk.git@master
Patch Set: Reintroduce assertHelper for asserts without messages. Created 5 years, 3 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: pkg/compiler/lib/src/resolution/send_structure.dart
diff --git a/pkg/compiler/lib/src/resolution/send_structure.dart b/pkg/compiler/lib/src/resolution/send_structure.dart
index f2850cee5998fc60dcd358465e07dc2463a35921..dea1b2f6107c7f048d1ff698de9679945000ad63 100644
--- a/pkg/compiler/lib/src/resolution/send_structure.dart
+++ b/pkg/compiler/lib/src/resolution/send_structure.dart
@@ -32,35 +32,6 @@ abstract class SendStructure<R, A> extends SemanticSendStructure<R, A> {
R dispatch(SemanticSendVisitor<R, A> visitor, Send send, A arg);
}
-/// The structure for a [Send] of the form `assert(e)`.
-class AssertStructure<R, A> implements SendStructure<R, A> {
- const AssertStructure();
-
- R dispatch(SemanticSendVisitor<R, A> visitor, Send node, A arg) {
- return visitor.visitAssert(
- node,
- node.arguments.single,
- arg);
- }
-
- String toString() => 'assert';
-}
-
-/// The structure for a [Send] of the form an `assert` with less or more than
-/// one argument.
-class InvalidAssertStructure<R, A> implements SendStructure<R, A> {
- const InvalidAssertStructure();
-
- R dispatch(SemanticSendVisitor<R, A> visitor, Send node, A arg) {
- return visitor.errorInvalidAssert(
- node,
- node.argumentsNode,
- arg);
- }
-
- String toString() => 'invalid assert';
-}
-
/// The structure for a [Send] of the form `a ?? b`.
class IfNullStructure<R, A> implements SendStructure<R, A> {
const IfNullStructure();

Powered by Google App Engine
This is Rietveld 408576698