Skip to content

[SR-11677] Offer a better diagnostic when && is used in trailing where clause declaration #54086

@CodaFi

Description

@CodaFi
Previous ID SR-11677
Radar rdar://38225184
Original Reporter @CodaFi
Type Bug
Status Resolved
Resolution Done
Additional Detail from JIRA
Votes 0
Component/s Compiler
Labels Bug, Parser, StarterBug
Assignee ninjiacoder (JIRA)
Priority Medium

md5: 50a519e5af58b06b95d65605733d7cf0

Issue Description:

We currently emit a pile of garbage diagnostics about this declaration. We should instead offer a concise diagnostic that replaces the && with a comma.

extension Collection where Element == Int && Index == Int {
  
}

Metadata

Metadata

Assignees

No one assigned

    Labels

    bugA deviation from expected or documented behavior. Also: expected but undesirable behavior.compilerThe Swift compiler itselfgood first issueGood for newcomersparserArea → compiler: The legacy C++ parser

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions