From 7b676db91d78d0b349f5f5618522477f07e18671 Mon Sep 17 00:00:00 2001 From: Arseniy Pendryak Date: Sat, 6 Aug 2022 11:33:05 +0200 Subject: [PATCH] Use `sync::LazyLock` instead of `lazy::SyncLazy` in `attributes-info` `lazy::SyncLazy` was renamed to `sync::LazyLock` in https://github.com/rust-lang/rust/pull/98165 --- attributes-info/rustc_span/src/symbol.rs | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/attributes-info/rustc_span/src/symbol.rs b/attributes-info/rustc_span/src/symbol.rs index 3606259c793..7f2f86743a6 100644 --- a/attributes-info/rustc_span/src/symbol.rs +++ b/attributes-info/rustc_span/src/symbol.rs @@ -5,15 +5,15 @@ use std::cmp::PartialEq; use std::fmt; use std::hash::Hash; -use std::lazy::SyncLazy; use std::str; +use std::sync::LazyLock; include!(concat!(env!("OUT_DIR"), "/symbol.rs")); #[derive(Copy, Clone, Eq, PartialEq, Hash)] pub struct Symbol(pub u32); -static INTERNER: SyncLazy = SyncLazy::new(|| Interner::fresh()); +static INTERNER: LazyLock = LazyLock::new(|| Interner::fresh()); impl Symbol { const fn new(n: u32) -> Self {