Skip to content

Commit db6b4d0

Browse files
authored
Bump MSRV to 1.85 and switch to the 2024 edition (#3126)
Running `cargo fix --edition` produces a lot of noise, and the relative drop order change shouldn't affect us because we don't use any unsafe code. What I did was manually change the edition and then just fix the compiler errors.
1 parent d70903b commit db6b4d0

File tree

58 files changed

+113
-133
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

58 files changed

+113
-133
lines changed

.github/workflows/ci.yml

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -3,8 +3,8 @@ name: CI
33
on: [push, pull_request]
44

55
env:
6-
rust_min: 1.82.0
7-
rust_nightly: nightly-2024-11-01
6+
rust_min: 1.85.0
7+
rust_nightly: nightly-2025-02-19
88

99
jobs:
1010
test:

Cargo.toml

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -23,8 +23,8 @@ homepage = "https://github.com/serenity-rs/serenity"
2323
repository = "https://github.com/serenity-rs/serenity.git"
2424
keywords = ["discord", "api"]
2525
license = "ISC"
26-
edition = "2021"
27-
rust-version = "1.82"
26+
edition = "2024"
27+
rust-version = "1.85"
2828

2929
[dependencies]
3030
# Required dependencies

README.md

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -100,7 +100,7 @@ tokio = { version = "1.21.2", features = ["macros", "rt-multi-thread"] }
100100

101101
## MSRV Policy
102102

103-
Serenity's minimum supported Rust version (MSRV) is Rust 1.82.
103+
Serenity's minimum supported Rust version (MSRV) is Rust 1.85.
104104

105105
We opt to keep MSRV stable on the `current` branch. This means it will remain
106106
unchanged between minor releases. Occasionally, dependencies may violate SemVer
@@ -244,5 +244,5 @@ a Rust-native cloud development platform that allows deploying Serenity bots for
244244
[repo:andesite]: https://github.com/natanbc/andesite
245245
[repo:lavaplayer]: https://github.com/sedmelluq/lavaplayer
246246
[logo]: https://raw.githubusercontent.com/serenity-rs/serenity/current/logo.png
247-
[rust-version-badge]: https://img.shields.io/badge/rust-1.82.0+-93450a.svg?style=flat-square
248-
[rust-version-link]: https://blog.rust-lang.org/2024/10/17/Rust-1.82.0.html
247+
[rust-version-badge]: https://img.shields.io/badge/rust-1.85.0+-93450a.svg?style=flat-square
248+
[rust-version-link]: https://blog.rust-lang.org/2025/02/20/Rust-1.85.0.html

examples/e01_basic_ping_bot/Cargo.toml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@
22
name = "e01_basic_ping_bot"
33
version = "0.1.0"
44
authors = ["my name <[email protected]>"]
5-
edition = "2018"
5+
edition.workspace = true
66

77
[dependencies]
88
serenity = { path = "../../", default-features = false, features = ["gateway", "model", "rustls_backend"] }

examples/e02_transparent_guild_sharding/Cargo.toml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@
22
name = "e02_transparent_guild_sharding"
33
version = "0.1.0"
44
authors = ["my name <[email protected]>"]
5-
edition = "2018"
5+
edition.workspace = true
66

77
[dependencies]
88
serenity = { path = "../../", default-features = false, features = ["gateway", "model", "rustls_backend"] }

examples/e03_struct_utilities/Cargo.toml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@
22
name = "e03_struct_utilities"
33
version = "0.1.0"
44
authors = ["my name <[email protected]>"]
5-
edition = "2018"
5+
edition.workspace = true
66

77
[dependencies]
88
serenity = { path = "../../", default-features = false, features = ["gateway", "model", "rustls_backend"] }

examples/e04_message_builder/Cargo.toml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@
22
name = "e04_message_builder"
33
version = "0.1.0"
44
authors = ["my name <[email protected]>"]
5-
edition = "2018"
5+
edition.workspace = true
66

77
[dependencies]
88
serenity = { path = "../../", default-features = false, features = ["gateway", "model", "rustls_backend"] }

examples/e05_sample_bot_structure/Cargo.toml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@
22
name = "e05_sample_bot_structure"
33
version = "0.1.0"
44
authors = ["my name <[email protected]>"]
5-
edition = "2021"
5+
edition.workspace = true
66

77
[dependencies]
88
serenity = { path = "../../", default-features = false, features = ["collector", "rustls_backend"] }

examples/e06_env_logging/Cargo.toml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@
22
name = "e06_env_logging"
33
version = "0.1.0"
44
authors = ["my name <[email protected]>"]
5-
edition = "2018"
5+
edition.workspace = true
66

77
[dependencies]
88
tracing = "0.1.23"

examples/e07_shard_manager/Cargo.toml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@
22
name = "e07_shard_manager"
33
version = "0.1.0"
44
authors = ["my name <[email protected]>"]
5-
edition = "2018"
5+
edition.workspace = true
66

77
[dependencies]
88
tokio = { version = "1.0", features = ["macros", "rt-multi-thread", "time"] }

0 commit comments

Comments
 (0)