Reputation: 3390
I am trying to update cargo: cargo install cargo-update
, but I'm faced with the following error:
Compiling semver-parser v0.7.0
error: the `?` operator is not stable (see issue #31436)
--> /home/netlab/.cargo/registry/src/github.com-1ecc6299db9ec823/semver-parser-0.7.0/src/version.rs:56:26
|
56 | let (pre, pre_len) = common::parse_optional_meta(&s[i..], b'-')?;
| ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
error: the `?` operator is not stable (see issue #31436)
--> /home/netlab/.cargo/registry/src/github.com-1ecc6299db9ec823/semver-parser-0.7.0/src/version.rs:58:30
|
58 | let (build, build_len) = common::parse_optional_meta(&s[i..], b'+')?;
| ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
error: the `?` operator is not stable (see issue #31436)
--> /home/netlab/.cargo/registry/src/github.com-1ecc6299db9ec823/semver-parser-0.7.0/src/range.rs:133:26
|
133 | let (pre, pre_len) = common::parse_optional_meta(&s[i..], b'-')?;
| ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
Upvotes: 1
Views: 181
Reputation: 2654
It depends on your Rust version — with versions of Rust before 1.13 you will receive the error because the operator wasn't stable in these versions.
Your error message refers to a GitHub issue number.
Upvotes: 1