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

Update rust toolchain to v1.81.0 #442

Merged
merged 4 commits into from
Oct 22, 2024
Merged

Conversation

mohanson
Copy link
Collaborator

@mohanson mohanson commented Oct 22, 2024

Updated to be consistent with ckb https://github.com/nervosnetwork/ckb/blob/develop/rust-toolchain.toml

Note that cargo gave a warning after the update, so I added a lints config in Cargo.toml as cargo suggested.

--> src/machine/mod.rs:1:7
  |
1 | #[cfg(has_asm)]
  |       ^^^^^^^
  |
  = help: expected names are: `clippy`, `debug_assertions`, `doc`, `docsrs`, `doctest`, `feature`, `miri`, `overflow_checks`, `panic`, `proc_macro`, `relocation_model`, `rustfmt`, `sanitize`, `sanitizer_cfi_generalize_pointers`, `sanitizer_cfi_normalize_integers`, `target_abi`, `target_arch`, `target_endian`, `target_env`, `target_family`, `target_feature`, `target_has_atomic`, `target_has_atomic_equal_alignment`, `target_has_atomic_load_store`, `target_os`, `target_pointer_width`, `target_thread_local`, `target_vendor`, `test`, `ub_checks`, `unix`, and `windows`
  = help: consider using a Cargo feature instead
  = help: or consider adding in `Cargo.toml` the `check-cfg` lint config for the lint:
           [lints.rust]
           unexpected_cfgs = { level = "warn", check-cfg = ['cfg(has_asm)'] }
  = help: or consider adding `println!("cargo::rustc-check-cfg=cfg(has_asm)");` to the top of the `build.rs`
  = note: see <https://doc.rust-lang.org/nightly/rustc/check-cfg/cargo-specifics.html> for more information about checking conditional configuration
  = note: `#[warn(unexpected_cfgs)]` on by default

Avoid to use legacy numeric method

```text
error: usage of a legacy numeric method
  --> src/lib.rs:62:14
   |
62 |         u64::max_value(),
   |              ^^^^^^^^^^^
   |
   = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#legacy_numeric_constants

XuJiandong
XuJiandong previously approved these changes Oct 22, 2024
@mohanson mohanson merged commit f7b9f20 into nervosnetwork:develop Oct 22, 2024
11 checks passed
@mohanson mohanson deleted the toolchain branch October 22, 2024 12:00
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

Successfully merging this pull request may close these issues.

3 participants