Index: pkg/analyzer/lib/src/generated/error_verifier.dart |
diff --git a/pkg/analyzer/lib/src/generated/error_verifier.dart b/pkg/analyzer/lib/src/generated/error_verifier.dart |
index 0d6ecf83ff5ee7a4c3b5e83705b724de0a531009..25e35f73925b26ae3f167246f8f6fe281345a14d 100644 |
--- a/pkg/analyzer/lib/src/generated/error_verifier.dart |
+++ b/pkg/analyzer/lib/src/generated/error_verifier.dart |
@@ -296,21 +296,10 @@ class ErrorVerifier extends RecursiveAstVisitor<Object> { |
final bool enableSuperMixins; |
/** |
- * If `true`, asserts are allowed to take a second argument representing the |
- * assertion failure message (see DEP 37). |
- */ |
- final bool enableAssertMessage; |
- |
- /** |
* Initialize a newly created error verifier. |
*/ |
- ErrorVerifier( |
- this._errorReporter, |
- this._currentLibrary, |
- this._typeProvider, |
- this._inheritanceManager, |
- this.enableSuperMixins, |
- this.enableAssertMessage) { |
+ ErrorVerifier(this._errorReporter, this._currentLibrary, this._typeProvider, |
+ this._inheritanceManager, this.enableSuperMixins) { |
this._isInSystemLibrary = _currentLibrary.source.isInSystemLibrary; |
this._hasExtUri = _currentLibrary.hasExtUri; |
_isEnclosingConstructorConst = false; |
@@ -349,14 +338,12 @@ class ErrorVerifier extends RecursiveAstVisitor<Object> { |
@override |
Object visitAssertInitializer(AssertInitializer node) { |
_checkForNonBoolExpression(node); |
- _checkAssertMessage(node); |
return super.visitAssertInitializer(node); |
} |
@override |
Object visitAssertStatement(AssertStatement node) { |
_checkForNonBoolExpression(node); |
- _checkAssertMessage(node); |
return super.visitAssertStatement(node); |
} |
@@ -1302,18 +1289,6 @@ class ErrorVerifier extends RecursiveAstVisitor<Object> { |
} |
/** |
- * If the given [assertion] specifies a message, verify that support |
- * for assertions with messages is enabled. |
- */ |
- void _checkAssertMessage(Assertion assertion) { |
- Expression expression = assertion.message; |
- if (expression != null && !enableAssertMessage) { |
- _errorReporter.reportErrorForNode( |
- CompileTimeErrorCode.EXTRA_ARGUMENT_TO_ASSERT, expression); |
- } |
- } |
- |
- /** |
* Given a list of [directives] that have the same prefix, generate an error |
* if there is more than one import and any of those imports is deferred. |
* |