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

Unified Diff: pkg/front_end/messages.yaml

Issue 2926953004: Various semantic checks on formal parameters. (Closed)
Patch Set: Added missing FASTA_IGNORED and rebased on aa8ca9244a3cc5fa7c3816a9340558e7d2f37ae1. Created 3 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
Index: pkg/front_end/messages.yaml
diff --git a/pkg/front_end/messages.yaml b/pkg/front_end/messages.yaml
index db1e55d5a56f4de197a4d29081d91f7c534617cb..f441bcc7c5019f7f5d44857a872779cc97a4f9e4 100644
--- a/pkg/front_end/messages.yaml
+++ b/pkg/front_end/messages.yaml
@@ -406,3 +406,26 @@ AssertExtraneousArgument:
AssertAsExpression:
template: "`assert` can't be used as an expression."
dart2jsCode: FASTA_FATAL
+
+FunctionTypeDefaultValue:
+ template: "Can't have a default value in a function type."
+ dart2jsCode: FASTA_IGNORED
+
+PrivateNamedParameter:
+ template: "An optional named parameter can't start with '_'."
+ dart2jsCode: FASTA_IGNORED
danrubel 2017/06/09 17:08:52 If fasta recognizes these errors, then should they
ahe 2017/06/09 18:53:31 The code "FASTA_IGNORED" doesn't mean that Fasta i
+
+NoFormals:
+ template: "A function should have formal parameters."
+ tip: "Try adding '()' after '#lexeme', or add 'get' before '#lexeme' to declare a getter."
+ dart2jsCode: FASTA_IGNORED
+
+GetterWithFormals:
+ template: "A getter can't have formal parameters."
+ tip: "Try removing '(...)'."
+ dart2jsCode: FASTA_IGNORED
+
+CatchSyntax:
+ template: "'catch' must be followed by '(identifier)' or '(identifier, identifier)'."
+ tip: "No types are needed, the first is given by 'on', the second is always 'StackTrace'."
+ dart2jsCode: FASTA_IGNORED

Powered by Google App Engine
This is Rietveld 408576698