Skip to content

Commit 3ed7f06

Browse files
committed
Fix fallout in libs. For the most part I just tagged impls as #[old_impl_check].
1 parent 6539cb4 commit 3ed7f06

File tree

11 files changed

+39
-3
lines changed

11 files changed

+39
-3
lines changed

src/libcollections/btree/node.rs

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1417,7 +1417,7 @@ pub type MutTraversal<'a, K, V> = AbsTraversal<ElemsAndEdges<Zip<slice::Iter<'a,
14171417
/// An owning traversal over a node's entries and edges
14181418
pub type MoveTraversal<K, V> = AbsTraversal<MoveTraversalImpl<K, V>>;
14191419

1420-
1420+
#[old_impl_check]
14211421
impl<K, V, E, Impl: TraversalImpl<K, V, E>> Iterator for AbsTraversal<Impl> {
14221422
type Item = TraversalItem<K, V, E>;
14231423

@@ -1433,6 +1433,7 @@ impl<K, V, E, Impl: TraversalImpl<K, V, E>> Iterator for AbsTraversal<Impl> {
14331433
}
14341434
}
14351435

1436+
#[old_impl_check]
14361437
impl<K, V, E, Impl: TraversalImpl<K, V, E>> DoubleEndedIterator for AbsTraversal<Impl> {
14371438
fn next_back(&mut self) -> Option<TraversalItem<K, V, E>> {
14381439
let tail_is_edge = self.tail_is_edge;

src/libcollections/lib.rs

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -26,6 +26,7 @@
2626
#![feature(unsafe_destructor, slicing_syntax)]
2727
#![feature(unboxed_closures)]
2828
#![feature(old_orphan_check)]
29+
#![feature(old_impl_check)]
2930
#![feature(associated_types)]
3031
#![no_std]
3132

src/librustc/lib.rs

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -28,6 +28,7 @@
2828
#![feature(rustc_diagnostic_macros)]
2929
#![feature(unboxed_closures)]
3030
#![feature(old_orphan_check)]
31+
#![feature(old_impl_check)]
3132
#![feature(associated_types)]
3233

3334
extern crate arena;

src/librustc/util/ppaux.rs

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1349,6 +1349,7 @@ impl<'tcx, T:Repr<'tcx>> Repr<'tcx> for ty::Binder<T> {
13491349
}
13501350
}
13511351

1352+
#[old_impl_check]
13521353
impl<'tcx, S, H, K, V> Repr<'tcx> for HashMap<K,V,H>
13531354
where K : Hash<S> + Eq + Repr<'tcx>,
13541355
V : Repr<'tcx>,

src/libserialize/collection_impls.rs

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -156,6 +156,7 @@ impl<
156156
}
157157
}
158158

159+
#[old_impl_check]
159160
impl<
160161
K: Encodable + Hash<X> + Eq,
161162
V: Encodable,
@@ -175,6 +176,7 @@ impl<
175176
}
176177
}
177178

179+
#[old_impl_check]
178180
impl<
179181
K: Decodable + Hash<S> + Eq,
180182
V: Decodable,
@@ -195,6 +197,7 @@ impl<
195197
}
196198
}
197199

200+
#[old_impl_check]
198201
impl<
199202
T: Encodable + Hash<X> + Eq,
200203
X,
@@ -212,6 +215,7 @@ impl<
212215
}
213216
}
214217

218+
#[old_impl_check]
215219
impl<
216220
T: Decodable + Hash<S> + Eq,
217221
S,

src/libserialize/lib.rs

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -26,6 +26,7 @@ Core encoding and decoding interfaces.
2626
#![feature(macro_rules, default_type_params, phase, slicing_syntax, globs)]
2727
#![feature(unboxed_closures)]
2828
#![feature(associated_types)]
29+
#![feature(old_impl_check)]
2930

3031
// test harness access
3132
#[cfg(test)]

src/libstd/collections/hash/map.rs

Lines changed: 10 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -439,6 +439,7 @@ impl<K, V, M> SearchResult<K, V, M> {
439439
}
440440
}
441441

442+
#[old_impl_check]
442443
impl<K: Eq + Hash<S>, V, S, H: Hasher<S>> HashMap<K, V, H> {
443444
fn make_hash<X: ?Sized + Hash<S>>(&self, x: &X) -> SafeHash {
444445
table::make_hash(&self.hasher, x)
@@ -517,6 +518,7 @@ impl<K: Hash + Eq, V> HashMap<K, V, RandomSipHasher> {
517518
}
518519
}
519520

521+
#[old_impl_check]
520522
impl<K: Eq + Hash<S>, V, S, H: Hasher<S>> HashMap<K, V, H> {
521523
/// Creates an empty hashmap which will use the given hasher to hash keys.
522524
///
@@ -1191,6 +1193,7 @@ fn search_entry_hashed<'a, K, V, Q: ?Sized>(table: &'a mut RawTable<K,V>, hash:
11911193
}
11921194

11931195
#[stable]
1196+
#[old_impl_check]
11941197
impl<K: Eq + Hash<S>, V: PartialEq, S, H: Hasher<S>> PartialEq for HashMap<K, V, H> {
11951198
fn eq(&self, other: &HashMap<K, V, H>) -> bool {
11961199
if self.len() != other.len() { return false; }
@@ -1202,9 +1205,11 @@ impl<K: Eq + Hash<S>, V: PartialEq, S, H: Hasher<S>> PartialEq for HashMap<K, V,
12021205
}
12031206

12041207
#[stable]
1208+
#[old_impl_check]
12051209
impl<K: Eq + Hash<S>, V: Eq, S, H: Hasher<S>> Eq for HashMap<K, V, H> {}
12061210

12071211
#[stable]
1212+
#[old_impl_check]
12081213
impl<K: Eq + Hash<S> + Show, V: Show, S, H: Hasher<S>> Show for HashMap<K, V, H> {
12091214
fn fmt(&self, f: &mut fmt::Formatter) -> fmt::Result {
12101215
try!(write!(f, "{{"));
@@ -1219,6 +1224,7 @@ impl<K: Eq + Hash<S> + Show, V: Show, S, H: Hasher<S>> Show for HashMap<K, V, H>
12191224
}
12201225

12211226
#[stable]
1227+
#[old_impl_check]
12221228
impl<K: Eq + Hash<S>, V, S, H: Hasher<S> + Default> Default for HashMap<K, V, H> {
12231229
#[stable]
12241230
fn default() -> HashMap<K, V, H> {
@@ -1227,6 +1233,7 @@ impl<K: Eq + Hash<S>, V, S, H: Hasher<S> + Default> Default for HashMap<K, V, H>
12271233
}
12281234

12291235
#[stable]
1236+
#[old_impl_check]
12301237
impl<K: Hash<S> + Eq, Q: ?Sized, V, S, H: Hasher<S>> Index<Q> for HashMap<K, V, H>
12311238
where Q: BorrowFrom<K> + Hash<S> + Eq
12321239
{
@@ -1239,6 +1246,7 @@ impl<K: Hash<S> + Eq, Q: ?Sized, V, S, H: Hasher<S>> Index<Q> for HashMap<K, V,
12391246
}
12401247

12411248
#[stable]
1249+
#[old_impl_check]
12421250
impl<K: Hash<S> + Eq, Q: ?Sized, V, S, H: Hasher<S>> IndexMut<Q> for HashMap<K, V, H>
12431251
where Q: BorrowFrom<K> + Hash<S> + Eq
12441252
{
@@ -1472,6 +1480,7 @@ impl<'a, Q: ?Sized + 'a + ToOwned<K>, K: 'a, V: 'a> VacantEntry<'a, Q, K, V> {
14721480
}
14731481

14741482
#[stable]
1483+
#[old_impl_check]
14751484
impl<K: Eq + Hash<S>, V, S, H: Hasher<S> + Default> FromIterator<(K, V)> for HashMap<K, V, H> {
14761485
fn from_iter<T: Iterator<Item=(K, V)>>(iter: T) -> HashMap<K, V, H> {
14771486
let lower = iter.size_hint().0;
@@ -1482,6 +1491,7 @@ impl<K: Eq + Hash<S>, V, S, H: Hasher<S> + Default> FromIterator<(K, V)> for Has
14821491
}
14831492

14841493
#[stable]
1494+
#[old_impl_check]
14851495
impl<K: Eq + Hash<S>, V, S, H: Hasher<S>> Extend<(K, V)> for HashMap<K, V, H> {
14861496
fn extend<T: Iterator<Item=(K, V)>>(&mut self, mut iter: T) {
14871497
for (k, v) in iter {

src/libstd/collections/hash/set.rs

Lines changed: 15 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -128,6 +128,7 @@ impl<T: Hash + Eq> HashSet<T, RandomSipHasher> {
128128
}
129129
}
130130

131+
#[old_impl_check]
131132
impl<T: Eq + Hash<S>, S, H: Hasher<S>> HashSet<T, H> {
132133
/// Creates a new empty hash set which will use the given hasher to hash
133134
/// keys.
@@ -571,6 +572,7 @@ impl<T: Eq + Hash<S>, S, H: Hasher<S>> HashSet<T, H> {
571572
}
572573

573574
#[stable]
575+
#[old_impl_check]
574576
impl<T: Eq + Hash<S>, S, H: Hasher<S>> PartialEq for HashSet<T, H> {
575577
fn eq(&self, other: &HashSet<T, H>) -> bool {
576578
if self.len() != other.len() { return false; }
@@ -580,9 +582,11 @@ impl<T: Eq + Hash<S>, S, H: Hasher<S>> PartialEq for HashSet<T, H> {
580582
}
581583

582584
#[stable]
585+
#[old_impl_check]
583586
impl<T: Eq + Hash<S>, S, H: Hasher<S>> Eq for HashSet<T, H> {}
584587

585588
#[stable]
589+
#[old_impl_check]
586590
impl<T: Eq + Hash<S> + fmt::Show, S, H: Hasher<S>> fmt::Show for HashSet<T, H> {
587591
fn fmt(&self, f: &mut fmt::Formatter) -> fmt::Result {
588592
try!(write!(f, "{{"));
@@ -597,6 +601,7 @@ impl<T: Eq + Hash<S> + fmt::Show, S, H: Hasher<S>> fmt::Show for HashSet<T, H> {
597601
}
598602

599603
#[stable]
604+
#[old_impl_check]
600605
impl<T: Eq + Hash<S>, S, H: Hasher<S> + Default> FromIterator<T> for HashSet<T, H> {
601606
fn from_iter<I: Iterator<Item=T>>(iter: I) -> HashSet<T, H> {
602607
let lower = iter.size_hint().0;
@@ -607,6 +612,7 @@ impl<T: Eq + Hash<S>, S, H: Hasher<S> + Default> FromIterator<T> for HashSet<T,
607612
}
608613

609614
#[stable]
615+
#[old_impl_check]
610616
impl<T: Eq + Hash<S>, S, H: Hasher<S>> Extend<T> for HashSet<T, H> {
611617
fn extend<I: Iterator<Item=T>>(&mut self, mut iter: I) {
612618
for k in iter {
@@ -616,6 +622,7 @@ impl<T: Eq + Hash<S>, S, H: Hasher<S>> Extend<T> for HashSet<T, H> {
616622
}
617623

618624
#[stable]
625+
#[old_impl_check]
619626
impl<T: Eq + Hash<S>, S, H: Hasher<S> + Default> Default for HashSet<T, H> {
620627
#[stable]
621628
fn default() -> HashSet<T, H> {
@@ -624,6 +631,7 @@ impl<T: Eq + Hash<S>, S, H: Hasher<S> + Default> Default for HashSet<T, H> {
624631
}
625632

626633
#[stable]
634+
#[old_impl_check]
627635
impl<'a, 'b, T: Eq + Hash<S> + Clone, S, H: Hasher<S> + Default>
628636
BitOr<&'b HashSet<T, H>> for &'a HashSet<T, H> {
629637
type Output = HashSet<T, H>;
@@ -654,6 +662,7 @@ BitOr<&'b HashSet<T, H>> for &'a HashSet<T, H> {
654662
}
655663

656664
#[stable]
665+
#[old_impl_check]
657666
impl<'a, 'b, T: Eq + Hash<S> + Clone, S, H: Hasher<S> + Default>
658667
BitAnd<&'b HashSet<T, H>> for &'a HashSet<T, H> {
659668
type Output = HashSet<T, H>;
@@ -684,6 +693,7 @@ BitAnd<&'b HashSet<T, H>> for &'a HashSet<T, H> {
684693
}
685694

686695
#[stable]
696+
#[old_impl_check]
687697
impl<'a, 'b, T: Eq + Hash<S> + Clone, S, H: Hasher<S> + Default>
688698
BitXor<&'b HashSet<T, H>> for &'a HashSet<T, H> {
689699
type Output = HashSet<T, H>;
@@ -714,6 +724,7 @@ BitXor<&'b HashSet<T, H>> for &'a HashSet<T, H> {
714724
}
715725

716726
#[stable]
727+
#[old_impl_check]
717728
impl<'a, 'b, T: Eq + Hash<S> + Clone, S, H: Hasher<S> + Default>
718729
Sub<&'b HashSet<T, H>> for &'a HashSet<T, H> {
719730
type Output = HashSet<T, H>;
@@ -816,6 +827,7 @@ impl<'a, K: 'a> Iterator for Drain<'a, K> {
816827
}
817828

818829
#[stable]
830+
#[old_impl_check]
819831
impl<'a, T, S, H> Iterator for Intersection<'a, T, H>
820832
where T: Eq + Hash<S>, H: Hasher<S>
821833
{
@@ -839,6 +851,7 @@ impl<'a, T, S, H> Iterator for Intersection<'a, T, H>
839851
}
840852

841853
#[stable]
854+
#[old_impl_check]
842855
impl<'a, T, S, H> Iterator for Difference<'a, T, H>
843856
where T: Eq + Hash<S>, H: Hasher<S>
844857
{
@@ -862,6 +875,7 @@ impl<'a, T, S, H> Iterator for Difference<'a, T, H>
862875
}
863876

864877
#[stable]
878+
#[old_impl_check]
865879
impl<'a, T, S, H> Iterator for SymmetricDifference<'a, T, H>
866880
where T: Eq + Hash<S>, H: Hasher<S>
867881
{
@@ -872,6 +886,7 @@ impl<'a, T, S, H> Iterator for SymmetricDifference<'a, T, H>
872886
}
873887

874888
#[stable]
889+
#[old_impl_check]
875890
impl<'a, T, S, H> Iterator for Union<'a, T, H>
876891
where T: Eq + Hash<S>, H: Hasher<S>
877892
{

src/libstd/io/mod.rs

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1604,6 +1604,7 @@ pub struct IncomingConnections<'a, A: ?Sized +'a> {
16041604
inc: &'a mut A,
16051605
}
16061606

1607+
#[old_impl_check]
16071608
impl<'a, T, A: ?Sized + Acceptor<T>> Iterator for IncomingConnections<'a, A> {
16081609
type Item = IoResult<T>;
16091610

src/libstd/lib.rs

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -108,6 +108,7 @@
108108
#![feature(default_type_params, phase, lang_items, unsafe_destructor)]
109109
#![feature(slicing_syntax, unboxed_closures)]
110110
#![feature(old_orphan_check)]
111+
#![feature(old_impl_check)]
111112
#![feature(associated_types)]
112113

113114
// Don't link to std. We are std.

0 commit comments

Comments
 (0)