Skip to content

Commit f52b88e

Browse files
committed
Revert example change from PR 116392
1 parent fc75a4e commit f52b88e

File tree

1 file changed

+1
-4
lines changed

1 file changed

+1
-4
lines changed

library/std/src/thread/local.rs

+1-4
Original file line numberDiff line numberDiff line change
@@ -166,10 +166,7 @@ impl<T: 'static> fmt::Debug for LocalKey<T> {
166166
/// ```
167167
/// use std::cell::Cell;
168168
/// thread_local! {
169-
/// pub static FOO: Cell<u32> = const {
170-
/// let value = 1;
171-
/// Cell::new(value)
172-
/// };
169+
/// pub static FOO: Cell<u32> = const { Cell::new(1) };
173170
/// }
174171
///
175172
/// assert_eq!(FOO.get(), 1);

0 commit comments

Comments
 (0)