Skip to content

Historical where clause within angle brackets causes  #777

Open
@DougGregor

Description

@DougGregor

Issue Kind

Bad Diagnostic Produced

Source Code

func genFn<T : Prot where T.Blarg : Prot2>(_: T) -> Int {}

Description

We get these diagnostics:

1:21: Expected '>' to end generic parameter clause
1:21: Expected argument list in function declaration
1:42: Extraneous '>(_: T) -> Int {}' at top level

vs. the existing compiler's

error: 'where' clause next to generic parameters is obsolete, must be written following the declaration's type

Metadata

Metadata

Assignees

No one assigned

    Labels

    SwiftParserBugs in the (new) Parser written in SwiftbugSomething isn't working

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions