1
Fork 0

Rollup merge of #110203 - compiler-errors:rtn-dots, r=eholk

Remove `..` from return type notation

`@nikomatsakis` and I decided that using `..` in the return-type notation syntax is probably overkill.

r? `@eholk` since you reviewed the last one

Since this is piggybacking now totally off of a pre-existing syntax (parenthesized generics), let me know if you need any explanation of the logic here, since it's a bit more complicated now.
This commit is contained in:
Matthias Krüger 2023-04-12 20:56:22 +02:00 committed by GitHub
commit a34bcd70b2
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
27 changed files with 126 additions and 109 deletions

View file

@ -353,13 +353,7 @@ pub enum BadReturnTypeNotation {
#[diag(ast_lowering_bad_return_type_notation_inputs)]
Inputs {
#[primary_span]
#[suggestion(code = "(..)", applicability = "maybe-incorrect")]
span: Span,
},
#[diag(ast_lowering_bad_return_type_notation_needs_dots)]
NeedsDots {
#[primary_span]
#[suggestion(code = "(..)", applicability = "maybe-incorrect")]
#[suggestion(code = "()", applicability = "maybe-incorrect")]
span: Span,
},
#[diag(ast_lowering_bad_return_type_notation_output)]