Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

error[E0061]: this function takes 2 arguments but 1 argument was supplied #136

Closed
roniemartinez opened this issue Sep 15, 2023 · 1 comment

Comments

@roniemartinez
Copy link
Contributor

   Compiling spider v1.42.1
error[E0061]: this function takes 2 arguments but 1 argument was supplied
   --> /Users/roniemartinez/.cargo/registry/src/index.crates.io-6f17d22bba15001f/spider-1.42.1/src/website.rs:857:37
    |
857 |                         Some(cb) => cb(u),
    |                                     ^^--- an argument of type `std::option::Option<string_concat::String>` is missing
    |
help: provide the argument
    |
857 |                         Some(cb) => cb(u, /* std::option::Option<string_concat::String> */),
    |                                       ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~

error[E0308]: `match` arms have incompatible types
   --> /Users/roniemartinez/.cargo/registry/src/index.crates.io-6f17d22bba15001f/spider-1.42.1/src/website.rs:858:30
    |
856 |                       let link_result = match self.on_link_find_callback {
    |  _______________________________________-
857 | |                         Some(cb) => cb(u),
    | |                                     -----
    | |                                     |  |
    | |                                     |  here the type of `u` is inferred to be `CaseInsensitiveString`
    | |                                     this is found to be of type `(CaseInsensitiveString, std::option::Option<string_concat::String>)`
858 | |                         _ => u,
    | |                              ^ expected `(CaseInsensitiveString, ...)`, found `CaseInsensitiveString`
859 | |                     };
    | |_____________________- `match` arms have incompatible types
    |
    = note: expected tuple `(CaseInsensitiveString, std::option::Option<string_concat::String>)`
              found struct `CaseInsensitiveString`

Some errors have detailed explanations: E0061, E0308.
For more information about an error, try `rustc --explain E0061`.
error: could not compile `spider` (lib) due to 2 previous errors
j-mendez added a commit that referenced this issue Sep 15, 2023
@j-mendez
Copy link
Member

@roniemartinez thank you the issue and details. This is now fixed in v1.42.2.🙌

j-mendez added a commit that referenced this issue Sep 15, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants