You've already forked comprehensive-rust
mirror of
https://github.com/google/comprehensive-rust.git
synced 2025-07-05 06:00:30 +02:00
Update to Rust 2024 edition. (#2658)
This commit is contained in:
@ -1,7 +1,7 @@
|
||||
[package]
|
||||
name = "user-defined-types"
|
||||
version = "0.1.0"
|
||||
edition = "2021"
|
||||
edition = "2024"
|
||||
publish = false
|
||||
|
||||
[[bin]]
|
||||
|
@ -14,11 +14,7 @@ const DIGEST_SIZE: usize = 3;
|
||||
const FILL_VALUE: u8 = calculate_fill_value();
|
||||
|
||||
const fn calculate_fill_value() -> u8 {
|
||||
if DIGEST_SIZE < 10 {
|
||||
42
|
||||
} else {
|
||||
13
|
||||
}
|
||||
if DIGEST_SIZE < 10 { 42 } else { 13 }
|
||||
}
|
||||
|
||||
fn compute_digest(text: &str) -> [u8; DIGEST_SIZE] {
|
||||
|
Reference in New Issue
Block a user