You've already forked comprehensive-rust
mirror of
https://github.com/google/comprehensive-rust.git
synced 2025-07-17 19:37:48 +02:00
Update to Rust 2024 edition. (#2658)
This commit is contained in:
@ -1,7 +1,7 @@
|
||||
[package]
|
||||
name = "control-flow-basics"
|
||||
version = "0.1.0"
|
||||
edition = "2021"
|
||||
edition = "2024"
|
||||
publish = false
|
||||
|
||||
[[bin]]
|
||||
|
@ -8,11 +8,7 @@ minutes: 3
|
||||
|
||||
```rust,editable
|
||||
fn gcd(a: u32, b: u32) -> u32 {
|
||||
if b > 0 {
|
||||
gcd(b, a % b)
|
||||
} else {
|
||||
a
|
||||
}
|
||||
if b > 0 { gcd(b, a % b) } else { a }
|
||||
}
|
||||
|
||||
fn main() {
|
||||
|
Reference in New Issue
Block a user