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

Unified Diff: compiler/java/com/google/dart/compiler/parser/DartParser.java

Issue 10534082: Issue 3449. Enable default values for parameters in abstract and interface methods (Closed) Base URL: https://dart.googlecode.com/svn/branches/bleeding_edge/dart
Patch Set: Rollback changes from other CL Created 8 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 | « no previous file | compiler/java/com/google/dart/compiler/parser/ParserErrorCode.java » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: compiler/java/com/google/dart/compiler/parser/DartParser.java
diff --git a/compiler/java/com/google/dart/compiler/parser/DartParser.java b/compiler/java/com/google/dart/compiler/parser/DartParser.java
index d9ca7cb4a9b8c6be3935f85d7816b7856fa26c94..344de4125c338b101cbd53c285cfc537bd15c7a9 100644
--- a/compiler/java/com/google/dart/compiler/parser/DartParser.java
+++ b/compiler/java/com/google/dart/compiler/parser/DartParser.java
@@ -1339,20 +1339,6 @@ public class DartParser extends CompletionHooksParserBase {
}
}
- // Interface method declaration can not have default values for named parameters.
- if (isParsingInterface) {
- validateNoDefaultParameterValues(
- parameters,
- ParserErrorCode.DEFAULT_VALUE_CAN_NOT_BE_SPECIFIED_IN_INTERFACE);
- }
-
- // Abstract method declaration can not have default values for named parameters.
- if (modifiers.isAbstract()) {
- validateNoDefaultParameterValues(
- parameters,
- ParserErrorCode.DEFAULT_VALUE_CAN_NOT_BE_SPECIFIED_IN_ABSTRACT);
- }
-
// Parse initializer expressions for constructors.
List<DartInitializer> initializers = new ArrayList<DartInitializer>();
if (match(Token.COLON) && !(isParsingInterface || modifiers.isFactory())) {
« no previous file with comments | « no previous file | compiler/java/com/google/dart/compiler/parser/ParserErrorCode.java » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698