Skip to content

Commit ebec67b

Browse files
author
Jorge Aparicio
committed
---
yaml --- r: 169312 b: refs/heads/master c: a291a80 h: refs/heads/master v: v3
1 parent 5251c38 commit ebec67b

File tree

11 files changed

+10
-194
lines changed

11 files changed

+10
-194
lines changed

[refs]

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
---
2-
refs/heads/master: f11f3e7baeba3f5acf08cc6fbfee559c00e9f96e
2+
refs/heads/master: a291a80fbe1222fd708b1e5612b8056cf9311cae
33
refs/heads/snap-stage1: e33de59e47c5076a89eadeb38f4934f58a3618a6
44
refs/heads/snap-stage3: 5b3cd3900ceda838f5798c30ab96ceb41f962534
55
refs/heads/try: 5204084bd2e46af7cc6e0147430e44dd0d657bbb

trunk/src/libcollections/bit.rs

Lines changed: 0 additions & 15 deletions
Original file line numberDiff line numberDiff line change
@@ -164,21 +164,6 @@ pub struct Bitv {
164164
nbits: uint
165165
}
166166

167-
// NOTE(stage0): remove impl after a snapshot
168-
#[cfg(stage0)]
169-
// FIXME(Gankro): NopeNopeNopeNopeNope (wait for IndexGet to be a thing)
170-
impl Index<uint,bool> for Bitv {
171-
#[inline]
172-
fn index(&self, i: &uint) -> &bool {
173-
if self.get(*i).expect("index out of bounds") {
174-
&TRUE
175-
} else {
176-
&FALSE
177-
}
178-
}
179-
}
180-
181-
#[cfg(not(stage0))] // NOTE(stage0): remove cfg after a snapshot
182167
// FIXME(Gankro): NopeNopeNopeNopeNope (wait for IndexGet to be a thing)
183168
impl Index<uint> for Bitv {
184169
type Output = bool;

trunk/src/libcollections/btree/map.rs

Lines changed: 0 additions & 24 deletions
Original file line numberDiff line numberDiff line change
@@ -877,18 +877,6 @@ impl<K: Show, V: Show> Show for BTreeMap<K, V> {
877877
}
878878
}
879879

880-
// NOTE(stage0): remove impl after a snapshot
881-
#[cfg(stage0)]
882-
#[stable]
883-
impl<K: Ord, Sized? Q, V> Index<Q, V> for BTreeMap<K, V>
884-
where Q: BorrowFrom<K> + Ord
885-
{
886-
fn index(&self, key: &Q) -> &V {
887-
self.get(key).expect("no entry found for key")
888-
}
889-
}
890-
891-
#[cfg(not(stage0))] // NOTE(stage0): remove cfg after a snapshot
892880
#[stable]
893881
impl<K: Ord, Sized? Q, V> Index<Q> for BTreeMap<K, V>
894882
where Q: BorrowFrom<K> + Ord
@@ -900,18 +888,6 @@ impl<K: Ord, Sized? Q, V> Index<Q> for BTreeMap<K, V>
900888
}
901889
}
902890

903-
// NOTE(stage0): remove impl after a snapshot
904-
#[cfg(stage0)]
905-
#[stable]
906-
impl<K: Ord, Sized? Q, V> IndexMut<Q, V> for BTreeMap<K, V>
907-
where Q: BorrowFrom<K> + Ord
908-
{
909-
fn index_mut(&mut self, key: &Q) -> &mut V {
910-
self.get_mut(key).expect("no entry found for key")
911-
}
912-
}
913-
914-
#[cfg(not(stage0))] // NOTE(stage0): remove cfg after a snapshot
915891
#[stable]
916892
impl<K: Ord, Sized? Q, V> IndexMut<Q> for BTreeMap<K, V>
917893
where Q: BorrowFrom<K> + Ord

trunk/src/libcollections/ring_buf.rs

Lines changed: 0 additions & 22 deletions
Original file line numberDiff line numberDiff line change
@@ -1360,17 +1360,6 @@ impl<S: Writer, A: Hash<S>> Hash<S> for RingBuf<A> {
13601360
}
13611361
}
13621362

1363-
// NOTE(stage0): remove impl after a snapshot
1364-
#[cfg(stage0)]
1365-
#[stable]
1366-
impl<A> Index<uint, A> for RingBuf<A> {
1367-
#[inline]
1368-
fn index<'a>(&'a self, i: &uint) -> &'a A {
1369-
self.get(*i).expect("Out of bounds access")
1370-
}
1371-
}
1372-
1373-
#[cfg(not(stage0))] // NOTE(stage0): remove cfg after a snapshot
13741363
#[stable]
13751364
impl<A> Index<uint> for RingBuf<A> {
13761365
type Output = A;
@@ -1381,17 +1370,6 @@ impl<A> Index<uint> for RingBuf<A> {
13811370
}
13821371
}
13831372

1384-
// NOTE(stage0): remove impl after a snapshot
1385-
#[cfg(stage0)]
1386-
#[stable]
1387-
impl<A> IndexMut<uint, A> for RingBuf<A> {
1388-
#[inline]
1389-
fn index_mut<'a>(&'a mut self, i: &uint) -> &'a mut A {
1390-
self.get_mut(*i).expect("Out of bounds access")
1391-
}
1392-
}
1393-
1394-
#[cfg(not(stage0))] // NOTE(stage0): remove cfg after a snapshot
13951373
#[stable]
13961374
impl<A> IndexMut<uint> for RingBuf<A> {
13971375
type Output = A;

trunk/src/libcollections/vec.rs

Lines changed: 0 additions & 21 deletions
Original file line numberDiff line numberDiff line change
@@ -1190,17 +1190,6 @@ impl<S: hash::Writer, T: Hash<S>> Hash<S> for Vec<T> {
11901190
}
11911191
}
11921192

1193-
// NOTE(stage0): remove impl after a snapshot
1194-
#[cfg(stage0)]
1195-
#[experimental = "waiting on Index stability"]
1196-
impl<T> Index<uint,T> for Vec<T> {
1197-
#[inline]
1198-
fn index<'a>(&'a self, index: &uint) -> &'a T {
1199-
&self.as_slice()[*index]
1200-
}
1201-
}
1202-
1203-
#[cfg(not(stage0))] // NOTE(stage0): remove cfg after a snapshot
12041193
#[experimental = "waiting on Index stability"]
12051194
impl<T> Index<uint> for Vec<T> {
12061195
type Output = T;
@@ -1211,16 +1200,6 @@ impl<T> Index<uint> for Vec<T> {
12111200
}
12121201
}
12131202

1214-
// NOTE(stage0): remove impl after a snapshot
1215-
#[cfg(stage0)]
1216-
impl<T> IndexMut<uint,T> for Vec<T> {
1217-
#[inline]
1218-
fn index_mut<'a>(&'a mut self, index: &uint) -> &'a mut T {
1219-
&mut self.as_mut_slice()[*index]
1220-
}
1221-
}
1222-
1223-
#[cfg(not(stage0))] // NOTE(stage0): remove cfg after a snapshot
12241203
impl<T> IndexMut<uint> for Vec<T> {
12251204
type Output = T;
12261205

trunk/src/libcollections/vec_map.rs

Lines changed: 0 additions & 22 deletions
Original file line numberDiff line numberDiff line change
@@ -517,17 +517,6 @@ impl<V> Extend<(uint, V)> for VecMap<V> {
517517
}
518518
}
519519

520-
// NOTE(stage0): remove impl after a snapshot
521-
#[cfg(stage0)]
522-
#[stable]
523-
impl<V> Index<uint, V> for VecMap<V> {
524-
#[inline]
525-
fn index<'a>(&'a self, i: &uint) -> &'a V {
526-
self.get(i).expect("key not present")
527-
}
528-
}
529-
530-
#[cfg(not(stage0))] // NOTE(stage0): remove cfg after a snapshot
531520
impl<V> Index<uint> for VecMap<V> {
532521
type Output = V;
533522

@@ -537,17 +526,6 @@ impl<V> Index<uint> for VecMap<V> {
537526
}
538527
}
539528

540-
// NOTE(stage0): remove impl after a snapshot
541-
#[cfg(stage0)]
542-
#[stable]
543-
impl<V> IndexMut<uint, V> for VecMap<V> {
544-
#[inline]
545-
fn index_mut<'a>(&'a mut self, i: &uint) -> &'a mut V {
546-
self.get_mut(i).expect("key not present")
547-
}
548-
}
549-
550-
#[cfg(not(stage0))] // NOTE(stage0): remove cfg after a snapshot
551529
#[stable]
552530
impl<V> IndexMut<uint> for VecMap<V> {
553531
type Output = V;

trunk/src/libcore/ops.rs

Lines changed: 0 additions & 20 deletions
Original file line numberDiff line numberDiff line change
@@ -717,15 +717,6 @@ macro_rules! shr_impl {
717717

718718
shr_impl! { uint u8 u16 u32 u64 int i8 i16 i32 i64 }
719719

720-
// NOTE(stage0) remove trait after a snapshot
721-
#[cfg(stage0)]
722-
#[allow(missing_docs)]
723-
#[lang="index"]
724-
pub trait Index<Sized? Index, Sized? Result> for Sized? {
725-
/// The method for the indexing (`Foo[Bar]`) operation
726-
fn index<'a>(&'a self, index: &Index) -> &'a Result;
727-
}
728-
729720
/// The `Index` trait is used to specify the functionality of indexing operations
730721
/// like `arr[idx]` when used in an immutable context.
731722
///
@@ -755,7 +746,6 @@ pub trait Index<Sized? Index, Sized? Result> for Sized? {
755746
/// Foo[Foo];
756747
/// }
757748
/// ```
758-
#[cfg(not(stage0))] // NOTE(stage0) remove cfg after a snapshot
759749
#[lang="index"]
760750
pub trait Index<Sized? Index> for Sized? {
761751
type Sized? Output;
@@ -764,15 +754,6 @@ pub trait Index<Sized? Index> for Sized? {
764754
fn index<'a>(&'a self, index: &Index) -> &'a Self::Output;
765755
}
766756

767-
// NOTE(stage0) remove trait after a snapshot
768-
#[cfg(stage0)]
769-
#[allow(missing_docs)]
770-
#[lang="index_mut"]
771-
pub trait IndexMut<Sized? Index, Sized? Result> for Sized? {
772-
/// The method for the indexing (`Foo[Bar]`) operation
773-
fn index_mut<'a>(&'a mut self, index: &Index) -> &'a mut Result;
774-
}
775-
776757
/// The `IndexMut` trait is used to specify the functionality of indexing
777758
/// operations like `arr[idx]`, when used in a mutable context.
778759
///
@@ -802,7 +783,6 @@ pub trait IndexMut<Sized? Index, Sized? Result> for Sized? {
802783
/// &mut Foo[Foo];
803784
/// }
804785
/// ```
805-
#[cfg(not(stage0))] // NOTE(stage0) remove cfg after a snapshot
806786
#[lang="index_mut"]
807787
pub trait IndexMut<Sized? Index> for Sized? {
808788
type Sized? Output;

trunk/src/libcore/slice.rs

Lines changed: 0 additions & 22 deletions
Original file line numberDiff line numberDiff line change
@@ -531,17 +531,6 @@ impl<T> SliceExt for [T] {
531531
}
532532
}
533533

534-
// NOTE(stage0) remove impl after a snapshot
535-
#[cfg(stage0)]
536-
impl<T> ops::Index<uint, T> for [T] {
537-
fn index(&self, &index: &uint) -> &T {
538-
assert!(index < self.len());
539-
540-
unsafe { mem::transmute(self.repr().data.offset(index as int)) }
541-
}
542-
}
543-
544-
#[cfg(not(stage0))] // NOTE(stage0) remove cfg after a snapshot
545534
impl<T> ops::Index<uint> for [T] {
546535
type Output = T;
547536

@@ -552,17 +541,6 @@ impl<T> ops::Index<uint> for [T] {
552541
}
553542
}
554543

555-
// NOTE(stage0) remove impl after a snapshot
556-
#[cfg(stage0)]
557-
impl<T> ops::IndexMut<uint, T> for [T] {
558-
fn index_mut(&mut self, &index: &uint) -> &mut T {
559-
assert!(index < self.len());
560-
561-
unsafe { mem::transmute(self.repr().data.offset(index as int)) }
562-
}
563-
}
564-
565-
#[cfg(not(stage0))] // NOTE(stage0) remove cfg after a snapshot
566544
impl<T> ops::IndexMut<uint> for [T] {
567545
type Output = T;
568546

trunk/src/libserialize/json.rs

Lines changed: 0 additions & 21 deletions
Original file line numberDiff line numberDiff line change
@@ -1125,15 +1125,6 @@ impl Json {
11251125
}
11261126
}
11271127

1128-
// NOTE(stage0): remove impl after a snapshot
1129-
#[cfg(stage0)]
1130-
impl<'a> ops::Index<&'a str, Json> for Json {
1131-
fn index(&self, idx: & &str) -> &Json {
1132-
self.find(*idx).unwrap()
1133-
}
1134-
}
1135-
1136-
#[cfg(not(stage0))] // NOTE(stage0): remove cfg after a snapshot
11371128
impl<'a> ops::Index<&'a str> for Json {
11381129
type Output = Json;
11391130

@@ -1142,18 +1133,6 @@ impl<'a> ops::Index<&'a str> for Json {
11421133
}
11431134
}
11441135

1145-
// NOTE(stage0): remove impl after a snapshot
1146-
#[cfg(stage0)]
1147-
impl ops::Index<uint, Json> for Json {
1148-
fn index<'a>(&'a self, idx: &uint) -> &'a Json {
1149-
match self {
1150-
&Json::Array(ref v) => v.index(idx),
1151-
_ => panic!("can only index Json with uint if it is an array")
1152-
}
1153-
}
1154-
}
1155-
1156-
#[cfg(not(stage0))] // NOTE(stage0): remove cfg after a snapshot
11571136
impl ops::Index<uint> for Json {
11581137
type Output = Json;
11591138

trunk/src/libstd/collections/hash/map.rs

Lines changed: 0 additions & 26 deletions
Original file line numberDiff line numberDiff line change
@@ -1226,19 +1226,6 @@ impl<K: Eq + Hash<S>, V, S, H: Hasher<S> + Default> Default for HashMap<K, V, H>
12261226
}
12271227
}
12281228

1229-
// NOTE(stage0): remove impl after a snapshot
1230-
#[cfg(stage0)]
1231-
#[stable]
1232-
impl<K: Hash<S> + Eq, Sized? Q, V, S, H: Hasher<S>> Index<Q, V> for HashMap<K, V, H>
1233-
where Q: BorrowFrom<K> + Hash<S> + Eq
1234-
{
1235-
#[inline]
1236-
fn index<'a>(&'a self, index: &Q) -> &'a V {
1237-
self.get(index).expect("no entry found for key")
1238-
}
1239-
}
1240-
1241-
#[cfg(not(stage0))] // NOTE(stage0): remove cfg after a snapshot
12421229
#[stable]
12431230
impl<K: Hash<S> + Eq, Sized? Q, V, S, H: Hasher<S>> Index<Q> for HashMap<K, V, H>
12441231
where Q: BorrowFrom<K> + Hash<S> + Eq
@@ -1251,19 +1238,6 @@ impl<K: Hash<S> + Eq, Sized? Q, V, S, H: Hasher<S>> Index<Q> for HashMap<K, V, H
12511238
}
12521239
}
12531240

1254-
// NOTE(stage0): remove impl after a snapshot
1255-
#[cfg(stage0)]
1256-
#[stable]
1257-
impl<K: Hash<S> + Eq, Sized? Q, V, S, H: Hasher<S>> IndexMut<Q, V> for HashMap<K, V, H>
1258-
where Q: BorrowFrom<K> + Hash<S> + Eq
1259-
{
1260-
#[inline]
1261-
fn index_mut<'a>(&'a mut self, index: &Q) -> &'a mut V {
1262-
self.get_mut(index).expect("no entry found for key")
1263-
}
1264-
}
1265-
1266-
#[cfg(not(stage0))] // NOTE(stage0): remove cfg after a snapshot
12671241
#[stable]
12681242
impl<K: Hash<S> + Eq, Sized? Q, V, S, H: Hasher<S>> IndexMut<Q> for HashMap<K, V, H>
12691243
where Q: BorrowFrom<K> + Hash<S> + Eq

trunk/src/snapshots.txt

Lines changed: 9 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,12 @@
1+
S 2015-01-04 b2085d9
2+
freebsd-x86_64 50ccb6bf9c0645d0746a5167493a39b2be40c2d4
3+
linux-i386 b880b98d832c9a049b8ef6a50df50061e363de5a
4+
linux-x86_64 82a09c162474b69d2d1e4e8399086f3f0f4e31c3
5+
macos-i386 569055bb10d96ab25f78ecf2c80ffbccd5e69b8d
6+
macos-x86_64 cff1f9ebd63dae6890359b7d353bd9486d8ecdfc
7+
winnt-i386 553790fe493413287a19d17a42bf7225d3e2272d
8+
winnt-x86_64 bab0d13960afb7ccdd6bf11452de1b9c457cc3e9
9+
110
S 2015-01-02 c894171
211
freebsd-x86_64 ea8bcf75eada3539f5cbab51708eecf40d436b77
312
linux-i386 646ae265721e3cbe19404aae4fea4ffa1f1d90cf

0 commit comments

Comments
 (0)