Skip to content

Commit f505d4e

Browse files
committed
Migrate alloc to Rust 2024
1 parent 0e071c2 commit f505d4e

File tree

3 files changed

+3
-21
lines changed

3 files changed

+3
-21
lines changed

library/alloc/Cargo.toml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -8,7 +8,7 @@ repository = "https://github.com/rust-lang/rust.git"
88
description = "The Rust core allocation and collections library"
99
autotests = false
1010
autobenches = false
11-
edition = "2021"
11+
edition = "2024"
1212

1313
[lib]
1414
test = false

tests/ui/macros/std-2024-macros.rs

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,13 +1,13 @@
11
// Tests a small handful of macros in the standard library how they handle the
22
// new behavior introduced in 2024 that allows `const{}` expressions.
33

4+
//@ check-pass
5+
46
fn main() {
57
assert_eq!(0, const { 0 });
68
assert_eq!(const { 0 }, const { 0 });
79
assert_eq!(const { 0 }, 0);
810

911
let _: Vec<Vec<String>> = vec![const { vec![] }];
10-
//~^ ERROR: no rules expected keyword `const`
1112
let _: Vec<Vec<String>> = vec![const { vec![] }; 10];
12-
//~^ ERROR: no rules expected keyword `const`
1313
}

tests/ui/macros/std-2024-macros.stderr

Lines changed: 0 additions & 18 deletions
This file was deleted.

0 commit comments

Comments
 (0)