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

cargo install fails with compilation error #7

Open
squk opened this issue Apr 18, 2022 · 1 comment
Open

cargo install fails with compilation error #7

squk opened this issue Apr 18, 2022 · 1 comment

Comments

@squk
Copy link

squk commented Apr 18, 2022

$cargo install mocword

error[E0277]: expected a `Fn<(char,)>` closure, found `[char; 2]`
   --> /usr/local/google/home/cnieves/.cargo/registry/src/github.aaakk.us.kg-1ecc6299db9ec823/mocword-0.1.0/src/main.rs:312:56
    |
312 |             execute(conn, &args, line.trim_end_matches(&['\r', '\n']))?.join(" ")
    |                                       ---------------- ^^^^^^^^^^^^^ expected an `Fn<(char,)>` closure, found `[char; 2]`
    |                                       |
    |                                       required by a bound introduced by this call
    |
    = help: the trait `Fn<(char,)>` is not implemented for `[char; 2]`
    = note: required because of the requirements on the impl of `FnOnce<(char,)>` for `&[char; 2]`
    = note: required because of the requirements on the impl of `Pattern<'_>` for `&[char; 2]`

For more information about this error, try `rustc --explain E0277`.
@high-moctane
Copy link
Owner

high-moctane commented Apr 19, 2022

@squk Could you tell me your environment (OS, cargo, rustc versions)? I can't reproduce this error in my environment.

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