Added msrv to threadlocal initializer

This commit is contained in:
Quinn Sinclair 2024-03-03 15:42:03 +01:00
parent 28e11b31de
commit 08459b4dae
4 changed files with 18 additions and 2 deletions

View file

@ -35,3 +35,10 @@ fn main() {
//~^ ERROR: initializer for `thread_local` value can be made `const`
}
}
#[clippy::msrv = "1.58"]
fn f() {
thread_local! {
static TLS: i32 = 1;
}
}

View file

@ -35,3 +35,10 @@ fn main() {
//~^ ERROR: initializer for `thread_local` value can be made `const`
}
}
#[clippy::msrv = "1.58"]
fn f() {
thread_local! {
static TLS: i32 = 1;
}
}