]> git.lizzy.rs Git - rust.git/blobdiff - compiler/rustc_error_messages/locales/en-US/parse.ftl
Rollup merge of #107256 - JakobDegen:delete-sai, r=cjgillot
[rust.git] / compiler / rustc_error_messages / locales / en-US / parse.ftl
index 3401978caf5f0f305b0f6128baf0ac79c6f73784..a3e2002da781c230eff39d72ab2452466bf118e2 100644 (file)
@@ -2,6 +2,10 @@ parse_struct_literal_body_without_path =
     struct literal body without path
     .suggestion = you might have forgotten to add the struct literal inside the block
 
+parse_struct_literal_needing_parens =
+    invalid struct literal
+    .suggestion = you might need to surround the struct literal in parentheses
+
 parse_maybe_report_ambiguous_plus =
     ambiguous `+` in a type
     .suggestion = use parentheses to disambiguate
@@ -234,6 +238,7 @@ parse_const_let_mutually_exclusive = `const` and `let` are mutually exclusive
 
 parse_invalid_expression_in_let_else = a `{$operator}` expression cannot be directly assigned in `let...else`
 parse_invalid_curly_in_let_else = right curly brace `{"}"}` before `else` in a `let...else` statement not allowed
+parse_extra_if_in_let_else = remove the `if` if you meant to write a `let...else` statement
 
 parse_compound_assignment_expression_in_let = can't reassign to an uninitialized variable
     .suggestion = initialize the variable
@@ -368,3 +373,9 @@ parse_maybe_fn_typo_with_impl = you might have meant to write `impl` instead of
 
 parse_expected_fn_path_found_fn_keyword = expected identifier, found keyword `fn`
     .suggestion = use `Fn` to refer to the trait
+
+parse_where_clause_before_tuple_struct_body = where clauses are not allowed before tuple struct bodies
+    .label = unexpected where clause
+    .name_label = while parsing this tuple struct
+    .body_label = the struct body
+    .suggestion = move the body before the where clause