Skip to content

Commit 9f07d05

Browse files
committed
markers -> marker
1 parent 91ba66f commit 9f07d05

File tree

154 files changed

+332
-332
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

154 files changed

+332
-332
lines changed

src/liballoc/arc.rs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -74,7 +74,7 @@ use core::clone::Clone;
7474
use core::fmt::{self, Show};
7575
use core::cmp::{Eq, Ord, PartialEq, PartialOrd, Ordering};
7676
use core::default::Default;
77-
use core::markers::{Sync, Send};
77+
use core::marker::{Sync, Send};
7878
use core::mem::{min_align_of, size_of, drop};
7979
use core::mem;
8080
use core::nonzero::NonZero;

src/liballoc/boxed.rs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -18,7 +18,7 @@ use core::cmp::{PartialEq, PartialOrd, Eq, Ord, Ordering};
1818
use core::default::Default;
1919
use core::fmt;
2020
use core::hash::{self, Hash};
21-
use core::markers::Sized;
21+
use core::marker::Sized;
2222
use core::mem;
2323
use core::option::Option;
2424
use core::ptr::Unique;

src/liballoc/rc.rs

Lines changed: 12 additions & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -148,7 +148,7 @@ use core::cmp::{PartialEq, PartialOrd, Eq, Ord, Ordering};
148148
use core::default::Default;
149149
use core::fmt;
150150
use core::hash::{self, Hash};
151-
use core::markers;
151+
use core::marker;
152152
use core::mem::{transmute, min_align_of, size_of, forget};
153153
use core::nonzero::NonZero;
154154
use core::ops::{Deref, Drop};
@@ -175,8 +175,8 @@ pub struct Rc<T> {
175175
// FIXME #12808: strange names to try to avoid interfering with field accesses of the contained
176176
// type via Deref
177177
_ptr: NonZero<*mut RcBox<T>>,
178-
_nosend: markers::NoSend,
179-
_noshare: markers::NoSync
178+
_nosend: marker::NoSend,
179+
_noshare: marker::NoSync
180180
}
181181

182182
impl<T> Rc<T> {
@@ -201,8 +201,8 @@ impl<T> Rc<T> {
201201
strong: Cell::new(1),
202202
weak: Cell::new(1)
203203
})),
204-
_nosend: markers::NoSend,
205-
_noshare: markers::NoSync
204+
_nosend: marker::NoSend,
205+
_noshare: marker::NoSync
206206
}
207207
}
208208
}
@@ -223,8 +223,8 @@ impl<T> Rc<T> {
223223
self.inc_weak();
224224
Weak {
225225
_ptr: self._ptr,
226-
_nosend: markers::NoSend,
227-
_noshare: markers::NoSync
226+
_nosend: marker::NoSend,
227+
_noshare: marker::NoSync
228228
}
229229
}
230230
}
@@ -431,7 +431,7 @@ impl<T> Clone for Rc<T> {
431431
#[inline]
432432
fn clone(&self) -> Rc<T> {
433433
self.inc_strong();
434-
Rc { _ptr: self._ptr, _nosend: markers::NoSend, _noshare: markers::NoSync }
434+
Rc { _ptr: self._ptr, _nosend: marker::NoSend, _noshare: marker::NoSync }
435435
}
436436
}
437437

@@ -622,8 +622,8 @@ pub struct Weak<T> {
622622
// FIXME #12808: strange names to try to avoid interfering with
623623
// field accesses of the contained type via Deref
624624
_ptr: NonZero<*mut RcBox<T>>,
625-
_nosend: markers::NoSend,
626-
_noshare: markers::NoSync
625+
_nosend: marker::NoSend,
626+
_noshare: marker::NoSync
627627
}
628628

629629
#[experimental = "Weak pointers may not belong in this module."]
@@ -650,7 +650,7 @@ impl<T> Weak<T> {
650650
None
651651
} else {
652652
self.inc_strong();
653-
Some(Rc { _ptr: self._ptr, _nosend: markers::NoSend, _noshare: markers::NoSync })
653+
Some(Rc { _ptr: self._ptr, _nosend: marker::NoSend, _noshare: marker::NoSync })
654654
}
655655
}
656656
}
@@ -717,7 +717,7 @@ impl<T> Clone for Weak<T> {
717717
#[inline]
718718
fn clone(&self) -> Weak<T> {
719719
self.inc_weak();
720-
Weak { _ptr: self._ptr, _nosend: markers::NoSend, _noshare: markers::NoSync }
720+
Weak { _ptr: self._ptr, _nosend: marker::NoSend, _noshare: marker::NoSync }
721721
}
722722
}
723723

src/libcollections/btree/map.rs

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -480,7 +480,7 @@ enum Continuation<A, B> {
480480
/// boilerplate gets cut out.
481481
mod stack {
482482
use core::prelude::*;
483-
use core::markers;
483+
use core::marker;
484484
use core::mem;
485485
use core::ops::{Deref, DerefMut};
486486
use super::BTreeMap;
@@ -494,7 +494,7 @@ mod stack {
494494
/// where `&'static` can be used in any function expecting any lifetime reference.
495495
pub struct IdRef<'id, T: 'id> {
496496
inner: &'id mut T,
497-
marker: markers::InvariantLifetime<'id>
497+
marker: marker::InvariantLifetime<'id>
498498
}
499499

500500
impl<'id, T> Deref for IdRef<'id, T> {
@@ -536,7 +536,7 @@ mod stack {
536536
pub struct Pusher<'id, 'a, K:'a, V:'a> {
537537
map: &'a mut BTreeMap<K, V>,
538538
stack: Stack<K, V>,
539-
marker: markers::InvariantLifetime<'id>
539+
marker: marker::InvariantLifetime<'id>
540540
}
541541

542542
impl<'a, K, V> PartialSearchStack<'a, K, V> {
@@ -571,11 +571,11 @@ mod stack {
571571
let pusher = Pusher {
572572
map: self.map,
573573
stack: self.stack,
574-
marker: markers::InvariantLifetime
574+
marker: marker::InvariantLifetime
575575
};
576576
let node = IdRef {
577577
inner: unsafe { &mut *self.next },
578-
marker: markers::InvariantLifetime
578+
marker: marker::InvariantLifetime
579579
};
580580

581581
closure(pusher, node)

src/libcollections/lib.rs

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -124,8 +124,8 @@ mod std {
124124
pub use core::clone; // deriving(Clone)
125125
pub use core::cmp; // deriving(Eq, Ord, etc.)
126126
#[cfg(stage0)]
127-
pub use core::markers as kinds;
128-
pub use core::markers; // deriving(Copy)
127+
pub use core::marker as kinds;
128+
pub use core::marker; // deriving(Copy)
129129
pub use core::hash; // deriving(Hash)
130130
}
131131

@@ -140,7 +140,7 @@ mod prelude {
140140
pub use core::iter::{FromIterator, Extend, IteratorExt};
141141
pub use core::iter::{Iterator, DoubleEndedIterator, RandomAccessIterator};
142142
pub use core::iter::{ExactSizeIterator};
143-
pub use core::markers::{Copy, Send, Sized, Sync};
143+
pub use core::marker::{Copy, Send, Sized, Sync};
144144
pub use core::mem::drop;
145145
pub use core::ops::{Drop, Fn, FnMut, FnOnce};
146146
pub use core::option::Option;

src/libcollections/ring_buf.rs

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -20,7 +20,7 @@ use core::cmp::Ordering;
2020
use core::default::Default;
2121
use core::fmt;
2222
use core::iter::{self, repeat, FromIterator, RandomAccessIterator};
23-
use core::markers;
23+
use core::marker;
2424
use core::mem;
2525
use core::num::{Int, UnsignedInt};
2626
use core::ops::{Index, IndexMut};
@@ -534,7 +534,7 @@ impl<T> RingBuf<T> {
534534
head: self.head,
535535
cap: self.cap,
536536
ptr: self.ptr,
537-
marker: markers::ContravariantLifetime::<'a>,
537+
marker: marker::ContravariantLifetime::<'a>,
538538
}
539539
}
540540

@@ -1414,7 +1414,7 @@ pub struct IterMut<'a, T:'a> {
14141414
tail: uint,
14151415
head: uint,
14161416
cap: uint,
1417-
marker: markers::ContravariantLifetime<'a>,
1417+
marker: marker::ContravariantLifetime<'a>,
14181418
}
14191419

14201420
#[stable]

src/libcollections/slice.rs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -95,7 +95,7 @@ use core::cmp::Ordering::{self, Greater, Less};
9595
use core::cmp::{self, Ord, PartialEq};
9696
use core::iter::{Iterator, IteratorExt};
9797
use core::iter::{range, range_step, MultiplicativeIterator};
98-
use core::markers::Sized;
98+
use core::marker::Sized;
9999
use core::mem::size_of;
100100
use core::mem;
101101
use core::ops::{FnMut, SliceMut};

src/libcollections/vec.rs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -55,7 +55,7 @@ use core::default::Default;
5555
use core::fmt;
5656
use core::hash::{self, Hash};
5757
use core::iter::{repeat, FromIterator};
58-
use core::markers::{ContravariantLifetime, InvariantType};
58+
use core::marker::{ContravariantLifetime, InvariantType};
5959
use core::mem;
6060
use core::nonzero::NonZero;
6161
use core::num::{Int, UnsignedInt};

src/libcore/array.rs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -17,7 +17,7 @@
1717
use clone::Clone;
1818
use cmp::{PartialEq, Eq, PartialOrd, Ord, Ordering};
1919
use fmt;
20-
use markers::Copy;
20+
use marker::Copy;
2121
use ops::Deref;
2222
use option::Option;
2323

src/libcore/atomic.rs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -72,7 +72,7 @@
7272

7373
use self::Ordering::*;
7474

75-
use markers::Sync;
75+
use marker::Sync;
7676

7777
use intrinsics;
7878
use cell::UnsafeCell;

src/libcore/borrow.rs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -47,7 +47,7 @@
4747
use clone::Clone;
4848
use cmp::{Eq, Ord, Ordering, PartialEq, PartialOrd};
4949
use fmt;
50-
use markers::Sized;
50+
use marker::Sized;
5151
use ops::Deref;
5252
use option::Option;
5353
use self::Cow::*;

src/libcore/cell.rs

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -161,7 +161,7 @@ use clone::Clone;
161161
use cmp::PartialEq;
162162
use default::Default;
163163
use fmt;
164-
use markers::{Copy, Send};
164+
use marker::{Copy, Send};
165165
use ops::{Deref, DerefMut, Drop};
166166
use option::Option;
167167
use option::Option::{None, Some};
@@ -520,11 +520,11 @@ impl<'b, T> DerefMut for RefMut<'b, T> {
520520
///
521521
/// ```rust
522522
/// use std::cell::UnsafeCell;
523-
/// use std::markers;
523+
/// use std::marker;
524524
///
525525
/// struct NotThreadSafe<T> {
526526
/// value: UnsafeCell<T>,
527-
/// marker: markers::NoSync
527+
/// marker: marker::NoSync
528528
/// }
529529
/// ```
530530
///

src/libcore/clone.rs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -21,7 +21,7 @@
2121
2222
#![stable]
2323

24-
use markers::Sized;
24+
use marker::Sized;
2525

2626
/// A common trait for cloning an object.
2727
#[stable]

src/libcore/cmp.rs

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -43,7 +43,7 @@
4343

4444
use self::Ordering::*;
4545

46-
use markers::Sized;
46+
use marker::Sized;
4747
use option::Option::{self, Some, None};
4848

4949
/// Trait for equality comparisons which are [partial equivalence relations](
@@ -316,7 +316,7 @@ pub fn partial_max<T: PartialOrd>(v1: T, v2: T) -> Option<T> {
316316
mod impls {
317317
use cmp::{PartialOrd, Ord, PartialEq, Eq, Ordering};
318318
use cmp::Ordering::{Less, Greater, Equal};
319-
use markers::Sized;
319+
use marker::Sized;
320320
use option::Option;
321321
use option::Option::{Some, None};
322322

src/libcore/fmt/mod.rs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -15,7 +15,7 @@
1515
use any;
1616
use cell::{Cell, Ref, RefMut};
1717
use iter::{Iterator, IteratorExt, range};
18-
use markers::{Copy, Sized};
18+
use marker::{Copy, Sized};
1919
use mem;
2020
use option::Option;
2121
use option::Option::{Some, None};

src/libcore/iter.rs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -67,7 +67,7 @@ use num::{ToPrimitive, Int};
6767
use ops::{Add, Deref, FnMut};
6868
use option::Option;
6969
use option::Option::{Some, None};
70-
use std::markers::Sized;
70+
use std::marker::Sized;
7171
use uint;
7272

7373
/// An interface for dealing with "external iterators". These types of iterators

src/libcore/lib.rs

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -111,7 +111,7 @@ pub mod ptr;
111111

112112
/* Core language traits */
113113

114-
pub mod markers;
114+
pub mod marker;
115115
pub mod ops;
116116
pub mod cmp;
117117
pub mod clone;
@@ -151,8 +151,8 @@ mod std {
151151
pub use clone;
152152
pub use cmp;
153153
#[cfg(stage0)]
154-
pub use markers as kinds;
155-
pub use markers;
154+
pub use marker as kinds;
155+
pub use marker;
156156
pub use option;
157157
pub use fmt;
158158
pub use hash;

src/libcore/markers.rs renamed to src/libcore/marker.rs

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -87,7 +87,7 @@ pub trait Copy {
8787
///
8888
/// Users writing their own types with interior mutability (or anything
8989
/// else that is not thread-safe) should use the `NoSync` marker type
90-
/// (from `std::markers`) to ensure that the compiler doesn't
90+
/// (from `std::marker`) to ensure that the compiler doesn't
9191
/// consider the user-defined type to be `Sync`. Any types with
9292
/// interior mutability must also use the `std::cell::UnsafeCell` wrapper
9393
/// around the value(s) which can be mutated when behind a `&`
@@ -140,10 +140,10 @@ pub unsafe trait Sync {
140140
#[unstable = "likely to change with new variance strategy"]
141141
#[lang="covariant_type"]
142142
#[derive(PartialEq, Eq, PartialOrd, Ord)]
143-
pub struct CovariantType<Sized? T>;
143+
pub struct CovariantType<T: ?Sized>;
144144

145-
impl<Sized? T> Copy for CovariantType<T> {}
146-
impl<Sized? T> Clone for CovariantType<T> {
145+
impl<T: ?Sized> Copy for CovariantType<T> {}
146+
impl<T: ?Sized> Clone for CovariantType<T> {
147147
fn clone(&self) -> CovariantType<T> { *self }
148148
}
149149

src/libcore/mem.rs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -15,7 +15,7 @@
1515
1616
#![stable]
1717

18-
use markers::Sized;
18+
use marker::Sized;
1919
use intrinsics;
2020
use ptr;
2121

src/libcore/num/mod.rs

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -21,7 +21,7 @@ use cmp::{PartialEq, Eq};
2121
use cmp::{PartialOrd, Ord};
2222
use intrinsics;
2323
use iter::IteratorExt;
24-
use markers::Copy;
24+
use marker::Copy;
2525
use mem::size_of;
2626
use ops::{Add, Sub, Mul, Div, Rem, Neg};
2727
use ops::{Not, BitAnd, BitOr, BitXor, Shl, Shr};
@@ -992,7 +992,7 @@ impl_to_primitive_float! { f64 }
992992

993993
/// A generic trait for converting a number to a value.
994994
#[experimental = "trait is likely to be removed"]
995-
pub trait FromPrimitive : ::markers::Sized {
995+
pub trait FromPrimitive : ::marker::Sized {
996996
/// Convert an `int` to return an optional value of this type. If the
997997
/// value cannot be represented by this value, the `None` is returned.
998998
#[inline]

src/libcore/ops.rs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -63,7 +63,7 @@
6363

6464
use clone::Clone;
6565
use iter::{Step, Iterator,DoubleEndedIterator,ExactSizeIterator};
66-
use markers::Sized;
66+
use marker::Sized;
6767
use option::Option::{self, Some, None};
6868

6969
/// The `Drop` trait is used to run some code when a value goes out of scope. This

src/libcore/prelude.rs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -29,7 +29,7 @@
2929
//! ```
3030
3131
// Reexported core operators
32-
pub use markers::{Copy, Send, Sized, Sync};
32+
pub use marker::{Copy, Send, Sized, Sync};
3333
pub use ops::{Drop, Fn, FnMut, FnOnce};
3434

3535
// Reexported functions

src/libcore/ptr.rs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -92,7 +92,7 @@ use mem;
9292
use clone::Clone;
9393
use intrinsics;
9494
use option::Option::{self, Some, None};
95-
use markers::{Send, Sized, Sync};
95+
use marker::{Send, Sized, Sync};
9696

9797
use cmp::{PartialEq, Eq, Ord, PartialOrd};
9898
use cmp::Ordering::{self, Less, Equal, Greater};

0 commit comments

Comments
 (0)