@@ -313,7 +313,6 @@ impl<T: 'static> LocalKey<Cell<T>> {
313313 /// # Examples
314314 ///
315315 /// ```
316- /// #![feature(local_key_cell_methods)]
317316 /// use std::cell::Cell;
318317 ///
319318 /// thread_local! {
@@ -326,7 +325,7 @@ impl<T: 'static> LocalKey<Cell<T>> {
326325 ///
327326 /// assert_eq!(X.get(), 123);
328327 /// ```
329- #[ unstable ( feature = "local_key_cell_methods" , issue = "92122 " ) ]
328+ #[ stable ( feature = "local_key_cell_methods" , since = "CURRENT_RUSTC_VERSION " ) ]
330329 pub fn set ( & ' static self , value : T ) {
331330 self . initialize_with ( Cell :: new ( value) , |value, cell| {
332331 if let Some ( value) = value {
@@ -351,7 +350,6 @@ impl<T: 'static> LocalKey<Cell<T>> {
351350 /// # Examples
352351 ///
353352 /// ```
354- /// #![feature(local_key_cell_methods)]
355353 /// use std::cell::Cell;
356354 ///
357355 /// thread_local! {
@@ -360,7 +358,7 @@ impl<T: 'static> LocalKey<Cell<T>> {
360358 ///
361359 /// assert_eq!(X.get(), 1);
362360 /// ```
363- #[ unstable ( feature = "local_key_cell_methods" , issue = "92122 " ) ]
361+ #[ stable ( feature = "local_key_cell_methods" , since = "CURRENT_RUSTC_VERSION " ) ]
364362 pub fn get ( & ' static self ) -> T
365363 where
366364 T : Copy ,
@@ -381,7 +379,6 @@ impl<T: 'static> LocalKey<Cell<T>> {
381379 /// # Examples
382380 ///
383381 /// ```
384- /// #![feature(local_key_cell_methods)]
385382 /// use std::cell::Cell;
386383 ///
387384 /// thread_local! {
@@ -391,7 +388,7 @@ impl<T: 'static> LocalKey<Cell<T>> {
391388 /// assert_eq!(X.take(), Some(1));
392389 /// assert_eq!(X.take(), None);
393390 /// ```
394- #[ unstable ( feature = "local_key_cell_methods" , issue = "92122 " ) ]
391+ #[ stable ( feature = "local_key_cell_methods" , since = "CURRENT_RUSTC_VERSION " ) ]
395392 pub fn take ( & ' static self ) -> T
396393 where
397394 T : Default ,
@@ -412,7 +409,6 @@ impl<T: 'static> LocalKey<Cell<T>> {
412409 /// # Examples
413410 ///
414411 /// ```
415- /// #![feature(local_key_cell_methods)]
416412 /// use std::cell::Cell;
417413 ///
418414 /// thread_local! {
@@ -422,7 +418,7 @@ impl<T: 'static> LocalKey<Cell<T>> {
422418 /// assert_eq!(X.replace(2), 1);
423419 /// assert_eq!(X.replace(3), 2);
424420 /// ```
425- #[ unstable ( feature = "local_key_cell_methods" , issue = "92122 " ) ]
421+ #[ stable ( feature = "local_key_cell_methods" , since = "CURRENT_RUSTC_VERSION " ) ]
426422 pub fn replace ( & ' static self , value : T ) -> T {
427423 self . with ( |cell| cell. replace ( value) )
428424 }
@@ -444,7 +440,6 @@ impl<T: 'static> LocalKey<RefCell<T>> {
444440 /// # Example
445441 ///
446442 /// ```
447- /// #![feature(local_key_cell_methods)]
448443 /// use std::cell::RefCell;
449444 ///
450445 /// thread_local! {
@@ -453,7 +448,7 @@ impl<T: 'static> LocalKey<RefCell<T>> {
453448 ///
454449 /// X.with_borrow(|v| assert!(v.is_empty()));
455450 /// ```
456- #[ unstable ( feature = "local_key_cell_methods" , issue = "92122 " ) ]
451+ #[ stable ( feature = "local_key_cell_methods" , since = "CURRENT_RUSTC_VERSION " ) ]
457452 pub fn with_borrow < F , R > ( & ' static self , f : F ) -> R
458453 where
459454 F : FnOnce ( & T ) -> R ,
@@ -476,7 +471,6 @@ impl<T: 'static> LocalKey<RefCell<T>> {
476471 /// # Example
477472 ///
478473 /// ```
479- /// #![feature(local_key_cell_methods)]
480474 /// use std::cell::RefCell;
481475 ///
482476 /// thread_local! {
@@ -487,7 +481,7 @@ impl<T: 'static> LocalKey<RefCell<T>> {
487481 ///
488482 /// X.with_borrow(|v| assert_eq!(*v, vec![1]));
489483 /// ```
490- #[ unstable ( feature = "local_key_cell_methods" , issue = "92122 " ) ]
484+ #[ stable ( feature = "local_key_cell_methods" , since = "CURRENT_RUSTC_VERSION " ) ]
491485 pub fn with_borrow_mut < F , R > ( & ' static self , f : F ) -> R
492486 where
493487 F : FnOnce ( & mut T ) -> R ,
@@ -511,7 +505,6 @@ impl<T: 'static> LocalKey<RefCell<T>> {
511505 /// # Examples
512506 ///
513507 /// ```
514- /// #![feature(local_key_cell_methods)]
515508 /// use std::cell::RefCell;
516509 ///
517510 /// thread_local! {
@@ -524,7 +517,7 @@ impl<T: 'static> LocalKey<RefCell<T>> {
524517 ///
525518 /// X.with_borrow(|v| assert_eq!(*v, vec![1, 2, 3]));
526519 /// ```
527- #[ unstable ( feature = "local_key_cell_methods" , issue = "92122 " ) ]
520+ #[ stable ( feature = "local_key_cell_methods" , since = "CURRENT_RUSTC_VERSION " ) ]
528521 pub fn set ( & ' static self , value : T ) {
529522 self . initialize_with ( RefCell :: new ( value) , |value, cell| {
530523 if let Some ( value) = value {
@@ -551,7 +544,6 @@ impl<T: 'static> LocalKey<RefCell<T>> {
551544 /// # Examples
552545 ///
553546 /// ```
554- /// #![feature(local_key_cell_methods)]
555547 /// use std::cell::RefCell;
556548 ///
557549 /// thread_local! {
@@ -566,7 +558,7 @@ impl<T: 'static> LocalKey<RefCell<T>> {
566558 ///
567559 /// X.with_borrow(|v| assert!(v.is_empty()));
568560 /// ```
569- #[ unstable ( feature = "local_key_cell_methods" , issue = "92122 " ) ]
561+ #[ stable ( feature = "local_key_cell_methods" , since = "CURRENT_RUSTC_VERSION " ) ]
570562 pub fn take ( & ' static self ) -> T
571563 where
572564 T : Default ,
@@ -586,7 +578,6 @@ impl<T: 'static> LocalKey<RefCell<T>> {
586578 /// # Examples
587579 ///
588580 /// ```
589- /// #![feature(local_key_cell_methods)]
590581 /// use std::cell::RefCell;
591582 ///
592583 /// thread_local! {
@@ -598,7 +589,7 @@ impl<T: 'static> LocalKey<RefCell<T>> {
598589 ///
599590 /// X.with_borrow(|v| assert_eq!(*v, vec![1, 2, 3]));
600591 /// ```
601- #[ unstable ( feature = "local_key_cell_methods" , issue = "92122 " ) ]
592+ #[ stable ( feature = "local_key_cell_methods" , since = "CURRENT_RUSTC_VERSION " ) ]
602593 pub fn replace ( & ' static self , value : T ) -> T {
603594 self . with ( |cell| cell. replace ( value) )
604595 }
0 commit comments