Skip to content

Error message for mismatched type parameter count repeats "parameter(s)" twice #39732

Description

@shepmaster

In Rust 1.15.1 and nightly (24a70eb 2017-02-09)

fn foo<A, B>() {}

fn main() {
    foo::<u8>()
}

Produces the error:

error[E0089]: too few type parameters provided: expected 2 parameters parameters, found 1 parameter parameter
 --> src/main.rs:4:5
  |
4 |     foo::<u8>()
  |     ^^^^^^^^^ expected 2 type parameters

Specifically, my issue is with:

expected 2 parameters parameters, found 1 parameter parameter

Activity

  1. shepmaster commented on Feb 11, 2017

    @shepmaster
    MemberAuthor

    It certainly looks like it would be coming from this bit of code, but on first read it all looks reasonable.

  2. shepmaster commented on Feb 11, 2017

    @shepmaster
    MemberAuthor

    Oh, no E0089 is this bit. Makes more sense. Whipping up a patch.

  3. added a commit that references this issue on Feb 13, 2017
    4148711
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions