-
Notifications
You must be signed in to change notification settings - Fork 7
Open
Description
Apparently I cannot write this:
let _ = i.parse( tag("abcd").map(|_| ()) )?;As it would result in this error:
error[E0308]: mismatched types
--> examples/sync_http.rs:35:15
|
35 | let _ = i.parse(tag("abcd").map(|_| ()))?;
| ^^^^^ one type is more general than the other
|
::: /home/geal/.cargo/registry/src/github.com-1ecc6299db9ec823/nom-6.2.1/src/bytes/streaming.rs:34:6
|
34 | ) -> impl Fn(Input) -> IResult<Input, Input, Error>
| ----------------------------------------------
| |
| the expected opaque type
| the found opaque type
|
= note: expected associated type `<impl Fn<(&[u8],)> as FnOnce<(&[u8],)>>::Output`
found associated type `<impl Fn<(&[u8],)> as FnOnce<(&'a [u8],)>>::Output`
For more information about this error, try `rustc --explain E0308`.
error: could not compile `nom-bufreader` due to previous error
Metadata
Metadata
Assignees
Labels
No labels