Skip to content

Commit 77ed0c0

Browse files
alexcrichtonManishearth
authored andcommitted
Remove deprecated functionality
This removes a large array of deprecated functionality, regardless of how recently it was deprecated. The purpose of this commit is to clean out the standard libraries and compiler for the upcoming alpha release. Some notable compiler changes were to enable warnings for all now-deprecated command line arguments (previously the deprecated versions were silently accepted) as well as removing deriving(Zero) entirely (the trait was removed). The distribution no longer contains the libtime or libregex_macros crates. Both of these have been deprecated for some time and are available externally.
1 parent efef15b commit 77ed0c0

File tree

1 file changed

+3
-3
lines changed

1 file changed

+3
-3
lines changed

reference.md

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1478,19 +1478,19 @@ Constants should in general be preferred over statics, unless large amounts of
14781478
data are being stored, or single-address and mutability properties are required.
14791479

14801480
```
1481-
use std::sync::atomic;
1481+
use std::sync::atomic::{AtomicUint, Ordering, ATOMIC_UINT_INIT};;
14821482
14831483
// Note that ATOMIC_UINT_INIT is a *const*, but it may be used to initialize a
14841484
// static. This static can be modified, so it is not placed in read-only memory.
1485-
static COUNTER: atomic::AtomicUint = atomic::ATOMIC_UINT_INIT;
1485+
static COUNTER: AtomicUint = ATOMIC_UINT_INIT;
14861486
14871487
// This table is a candidate to be placed in read-only memory.
14881488
static TABLE: &'static [uint] = &[1, 2, 3, /* ... */];
14891489
14901490
for slot in TABLE.iter() {
14911491
println!("{}", slot);
14921492
}
1493-
COUNTER.fetch_add(1, atomic::SeqCst);
1493+
COUNTER.fetch_add(1, Ordering::SeqCst);
14941494
```
14951495

14961496
#### Mutable statics

0 commit comments

Comments
 (0)