diff options
| author | Patrick Walton <pcwalton@mimiga.net> | 2013-02-26 17:47:41 -0800 |
|---|---|---|
| committer | Patrick Walton <pcwalton@mimiga.net> | 2013-02-28 11:32:24 -0800 |
| commit | 107bf96ff0dcc427c1842ffb232d29afaea53ca5 (patch) | |
| tree | 8b335088a404957c76f31111b5e6e72c3dc9131a /src/test | |
| parent | b171d0ef7b68fed961597d38e6a474d748243987 (diff) | |
| download | rust-107bf96ff0dcc427c1842ffb232d29afaea53ca5.tar.gz rust-107bf96ff0dcc427c1842ffb232d29afaea53ca5.zip | |
librustc: Mark all type implementations public. rs=impl-publicity
Diffstat (limited to 'src/test')
63 files changed, 70 insertions, 70 deletions
diff --git a/src/test/auxiliary/impl_privacy_xc_1.rs b/src/test/auxiliary/impl_privacy_xc_1.rs index 05d5cee47f2..92452cbe8fd 100644 --- a/src/test/auxiliary/impl_privacy_xc_1.rs +++ b/src/test/auxiliary/impl_privacy_xc_1.rs @@ -4,7 +4,7 @@ pub struct Fish { x: int } -impl Fish { +pub impl Fish { fn swim(&self) {} } diff --git a/src/test/auxiliary/issue_2472_b.rs b/src/test/auxiliary/issue_2472_b.rs index e1be3adcd4a..e7a92954725 100644 --- a/src/test/auxiliary/issue_2472_b.rs +++ b/src/test/auxiliary/issue_2472_b.rs @@ -11,7 +11,7 @@ enum S = (); -impl S { +pub impl S { fn foo() { } } diff --git a/src/test/bench/core-set.rs b/src/test/bench/core-set.rs index 2845596e780..5e73b286530 100644 --- a/src/test/bench/core-set.rs +++ b/src/test/bench/core-set.rs @@ -31,7 +31,7 @@ fn timed(result: &mut float, op: fn()) { *result = (end - start); } -impl Results { +pub impl Results { fn bench_int<T:Set<uint>>(&mut self, rng: @rand::Rng, num_keys: uint, rand_cap: uint, f: fn() -> T) { { diff --git a/src/test/bench/noise.rs b/src/test/bench/noise.rs index 39caba92732..9825671bc8a 100644 --- a/src/test/bench/noise.rs +++ b/src/test/bench/noise.rs @@ -40,7 +40,7 @@ fn Noise2DContext() -> ~Noise2DContext { } } -impl Noise2DContext { +pub impl Noise2DContext { #[inline(always)] fn get_gradient(&self, x: int, y: int) -> Vec2 { let idx = self.permutations[x & 255] + self.permutations[y & 255]; diff --git a/src/test/compile-fail/assign-to-method.rs b/src/test/compile-fail/assign-to-method.rs index 7d68d6d0c38..0a2834a95e6 100644 --- a/src/test/compile-fail/assign-to-method.rs +++ b/src/test/compile-fail/assign-to-method.rs @@ -14,7 +14,7 @@ struct cat { how_hungry : int, } -impl cat { +pub impl cat { fn speak() { self.meows += 1u; } } diff --git a/src/test/compile-fail/borrowck-autoref-3261.rs b/src/test/compile-fail/borrowck-autoref-3261.rs index b3ef5f4d481..068bb7cd7a6 100644 --- a/src/test/compile-fail/borrowck-autoref-3261.rs +++ b/src/test/compile-fail/borrowck-autoref-3261.rs @@ -10,7 +10,7 @@ use core::either::*; enum X = Either<(uint,uint),extern fn()>; -impl &X { +pub impl &X { fn with(blk: fn(x: &Either<(uint,uint),extern fn()>)) { blk(&**self) } diff --git a/src/test/compile-fail/borrowck-call-method-from-mut-aliasable.rs b/src/test/compile-fail/borrowck-call-method-from-mut-aliasable.rs index 4e0cc76bf75..2c68429baec 100644 --- a/src/test/compile-fail/borrowck-call-method-from-mut-aliasable.rs +++ b/src/test/compile-fail/borrowck-call-method-from-mut-aliasable.rs @@ -12,7 +12,7 @@ struct Foo { x: int, } -impl Foo { +pub impl Foo { fn f(&self) {} fn g(&const self) {} fn h(&mut self) {} diff --git a/src/test/compile-fail/borrowck-insert-during-each.rs b/src/test/compile-fail/borrowck-insert-during-each.rs index e0fca586b6b..476a790b85e 100644 --- a/src/test/compile-fail/borrowck-insert-during-each.rs +++ b/src/test/compile-fail/borrowck-insert-during-each.rs @@ -14,7 +14,7 @@ struct Foo { n: LinearSet<int>, } -impl Foo { +pub impl Foo { fn foo(&mut self, fun: fn(&int)) { for self.n.each |f| { fun(f); diff --git a/src/test/compile-fail/borrowck-loan-rcvr-overloaded-op.rs b/src/test/compile-fail/borrowck-loan-rcvr-overloaded-op.rs index e15edd8cf19..61cf346ffa4 100644 --- a/src/test/compile-fail/borrowck-loan-rcvr-overloaded-op.rs +++ b/src/test/compile-fail/borrowck-loan-rcvr-overloaded-op.rs @@ -19,7 +19,7 @@ impl ops::Add<int,int> for Point { } } -impl Point { +pub impl Point { fn times(z: int) -> int { self.x * self.y * z } diff --git a/src/test/compile-fail/class-cast-to-trait.rs b/src/test/compile-fail/class-cast-to-trait.rs index 671298040a9..3169b0299a0 100644 --- a/src/test/compile-fail/class-cast-to-trait.rs +++ b/src/test/compile-fail/class-cast-to-trait.rs @@ -19,7 +19,7 @@ struct cat { name : ~str, } -impl cat { +pub impl cat { fn eat() -> bool { if self.how_hungry > 0 { diff --git a/src/test/compile-fail/issue-2356.rs b/src/test/compile-fail/issue-2356.rs index 30a9fadaeb0..9a574b984ca 100644 --- a/src/test/compile-fail/issue-2356.rs +++ b/src/test/compile-fail/issue-2356.rs @@ -14,6 +14,6 @@ struct cat { tail: int, } -impl cat { +pub impl cat { fn meow() { tail += 1; } //~ ERROR: Did you mean: `self.tail` } diff --git a/src/test/compile-fail/issue-2766-a.rs b/src/test/compile-fail/issue-2766-a.rs index 77a840e7e36..8ec63ddc634 100644 --- a/src/test/compile-fail/issue-2766-a.rs +++ b/src/test/compile-fail/issue-2766-a.rs @@ -14,7 +14,7 @@ pub mod stream { use core::option; use core::pipes; - impl<T:Owned> Stream<T> { + pub impl<T:Owned> Stream<T> { pub fn recv() -> extern fn(+v: Stream<T>) -> ::stream::Stream<T> { // resolve really should report just one error here. // Change the test case when it changes. diff --git a/src/test/compile-fail/issue-3021-b.rs b/src/test/compile-fail/issue-3021-b.rs index 1d4cd69c54e..e6d16042445 100644 --- a/src/test/compile-fail/issue-3021-b.rs +++ b/src/test/compile-fail/issue-3021-b.rs @@ -16,7 +16,7 @@ fn siphash(k0 : u64) { v0: u64, } - impl siphash { + pub impl siphash { fn reset(&mut self) { self.v0 = k0 ^ 0x736f6d6570736575; //~ ERROR attempted dynamic environment-capture //~^ ERROR unresolved name: `k0`. diff --git a/src/test/compile-fail/issue-3080.rs b/src/test/compile-fail/issue-3080.rs index d7a214dc76b..530dadd7e90 100644 --- a/src/test/compile-fail/issue-3080.rs +++ b/src/test/compile-fail/issue-3080.rs @@ -10,7 +10,7 @@ // xfail-test enum x = (); -impl x { +pub impl x { unsafe fn with() { } // This should fail } diff --git a/src/test/compile-fail/issue-3311.rs b/src/test/compile-fail/issue-3311.rs index a09a87d9a6b..1207ddcb9a0 100644 --- a/src/test/compile-fail/issue-3311.rs +++ b/src/test/compile-fail/issue-3311.rs @@ -14,7 +14,7 @@ struct Foo { u: ~() } -impl Foo { +pub impl Foo { fn get_s(&self) -> &self/str { self.s } diff --git a/src/test/compile-fail/issue-3707.rs b/src/test/compile-fail/issue-3707.rs index c166c400b36..040bd46ab8c 100644 --- a/src/test/compile-fail/issue-3707.rs +++ b/src/test/compile-fail/issue-3707.rs @@ -13,7 +13,7 @@ struct Obj { member: uint } -impl Obj { +pub impl Obj { static pure fn boom() -> bool { return 1+1 == 2 } diff --git a/src/test/compile-fail/issue-3763.rs b/src/test/compile-fail/issue-3763.rs index ea4b70c3c29..09a3f3d89c4 100644 --- a/src/test/compile-fail/issue-3763.rs +++ b/src/test/compile-fail/issue-3763.rs @@ -15,7 +15,7 @@ mod my_mod { pub fn MyStruct () -> MyStruct { MyStruct {priv_field: 4} } - impl MyStruct { + pub impl MyStruct { priv fn happyfun() {} } } diff --git a/src/test/compile-fail/mutable-class-fields-2.rs b/src/test/compile-fail/mutable-class-fields-2.rs index 04ba25fc07d..3a63cdee20c 100644 --- a/src/test/compile-fail/mutable-class-fields-2.rs +++ b/src/test/compile-fail/mutable-class-fields-2.rs @@ -15,7 +15,7 @@ struct cat { how_hungry : int, } -impl cat { +pub impl cat { fn eat() { self.how_hungry -= 5; } diff --git a/src/test/compile-fail/regions-addr-of-self.rs b/src/test/compile-fail/regions-addr-of-self.rs index c6c89a3ae04..96657edb5b1 100644 --- a/src/test/compile-fail/regions-addr-of-self.rs +++ b/src/test/compile-fail/regions-addr-of-self.rs @@ -12,7 +12,7 @@ struct dog { cats_chased: uint, } -impl dog { +pub impl dog { fn chase_cat(&mut self) { let p: &static/mut uint = &mut self.cats_chased; //~ ERROR cannot infer an appropriate lifetime due to conflicting requirements *p += 1u; diff --git a/src/test/compile-fail/regions-addr-of-upvar-self.rs b/src/test/compile-fail/regions-addr-of-upvar-self.rs index 8e98d4341a8..b9a9e2f38f5 100644 --- a/src/test/compile-fail/regions-addr-of-upvar-self.rs +++ b/src/test/compile-fail/regions-addr-of-upvar-self.rs @@ -12,7 +12,7 @@ struct dog { food: uint, } -impl dog { +pub impl dog { fn chase_cat(&mut self) { for uint::range(0u, 10u) |_i| { let p: &'static mut uint = &mut self.food; //~ ERROR cannot infer an appropriate lifetime due to conflicting requirements diff --git a/src/test/compile-fail/trait-or-new-type-instead.rs b/src/test/compile-fail/trait-or-new-type-instead.rs index 0634205140b..dc7c7cec65f 100644 --- a/src/test/compile-fail/trait-or-new-type-instead.rs +++ b/src/test/compile-fail/trait-or-new-type-instead.rs @@ -9,7 +9,7 @@ // except according to those terms. // error-pattern: implement a trait or new type instead -impl <T> Option<T> { +pub impl <T> Option<T> { fn foo() { } } diff --git a/src/test/compile-fail/use-after-move-self-based-on-type.rs b/src/test/compile-fail/use-after-move-self-based-on-type.rs index a06bc42d29a..b0a2bc8ec12 100644 --- a/src/test/compile-fail/use-after-move-self-based-on-type.rs +++ b/src/test/compile-fail/use-after-move-self-based-on-type.rs @@ -6,7 +6,7 @@ impl Drop for S { fn finalize(&self) {} } -impl S { +pub impl S { fn foo(self) -> int { self.bar(); return self.x; //~ ERROR use of moved value diff --git a/src/test/compile-fail/use-after-move-self.rs b/src/test/compile-fail/use-after-move-self.rs index 7ad41b518a1..3eded9fd4f3 100644 --- a/src/test/compile-fail/use-after-move-self.rs +++ b/src/test/compile-fail/use-after-move-self.rs @@ -2,7 +2,7 @@ struct S { x: ~int } -impl S { +pub impl S { fn foo(self) -> int { self.bar(); return *self.x; //~ ERROR use of moved value diff --git a/src/test/run-pass/anon-trait-static-method.rs b/src/test/run-pass/anon-trait-static-method.rs index 4143c12cf67..2ec0b59e13f 100644 --- a/src/test/run-pass/anon-trait-static-method.rs +++ b/src/test/run-pass/anon-trait-static-method.rs @@ -12,7 +12,7 @@ struct Foo { x: int } -impl Foo { +pub impl Foo { static fn new() -> Foo { Foo { x: 3 } } diff --git a/src/test/run-pass/auto-ref-newtype.rs b/src/test/run-pass/auto-ref-newtype.rs index 80f20b13bdd..1b4c22e80f3 100644 --- a/src/test/run-pass/auto-ref-newtype.rs +++ b/src/test/run-pass/auto-ref-newtype.rs @@ -13,7 +13,7 @@ enum Foo = uint; -impl Foo { +pub impl Foo { fn len(&self) -> uint { **self } } diff --git a/src/test/run-pass/autoderef-and-borrow-method-receiver.rs b/src/test/run-pass/autoderef-and-borrow-method-receiver.rs index 6e6d289e90f..883cffa792b 100644 --- a/src/test/run-pass/autoderef-and-borrow-method-receiver.rs +++ b/src/test/run-pass/autoderef-and-borrow-method-receiver.rs @@ -12,7 +12,7 @@ struct Foo { x: int, } -impl Foo { +pub impl Foo { fn f(&const self) {} } diff --git a/src/test/run-pass/borrowck-wg-borrow-mut-to-imm-3.rs b/src/test/run-pass/borrowck-wg-borrow-mut-to-imm-3.rs index 748672ef050..d8612155f6c 100644 --- a/src/test/run-pass/borrowck-wg-borrow-mut-to-imm-3.rs +++ b/src/test/run-pass/borrowck-wg-borrow-mut-to-imm-3.rs @@ -2,7 +2,7 @@ struct Wizard { spells: ~[&static/str] } -impl Wizard { +pub impl Wizard { fn cast(&mut self) { for self.spells.each |&spell| { io::println(spell); diff --git a/src/test/run-pass/class-cast-to-trait-multiple-types.rs b/src/test/run-pass/class-cast-to-trait-multiple-types.rs index f35a91c2b91..7c5d5c4d126 100644 --- a/src/test/run-pass/class-cast-to-trait-multiple-types.rs +++ b/src/test/run-pass/class-cast-to-trait-multiple-types.rs @@ -18,7 +18,7 @@ struct dog { volume : @mut int, } -impl dog { +pub impl dog { priv fn bark() -> int { debug!("Woof %u %d", *self.barks, *self.volume); *self.barks += 1u; @@ -55,7 +55,7 @@ impl noisy for cat { fn speak() -> int { self.meow() as int } } -impl cat { +pub impl cat { fn meow_count() -> uint { *self.meows } } diff --git a/src/test/run-pass/class-cast-to-trait.rs b/src/test/run-pass/class-cast-to-trait.rs index 157ea586c2c..581361c154c 100644 --- a/src/test/run-pass/class-cast-to-trait.rs +++ b/src/test/run-pass/class-cast-to-trait.rs @@ -22,7 +22,7 @@ impl noisy for cat { fn speak(&mut self) { self.meow(); } } -impl cat { +pub impl cat { fn eat(&mut self) -> bool { if self.how_hungry > 0 { error!("OM NOM NOM"); diff --git a/src/test/run-pass/class-impl-very-parameterized-trait.rs b/src/test/run-pass/class-impl-very-parameterized-trait.rs index 40f728d40bf..f71675c06be 100644 --- a/src/test/run-pass/class-impl-very-parameterized-trait.rs +++ b/src/test/run-pass/class-impl-very-parameterized-trait.rs @@ -34,7 +34,7 @@ struct cat<T> { name : T, } -impl<T> cat<T> { +pub impl<T> cat<T> { fn speak(&mut self) { self.meow(); } fn eat(&mut self) -> bool { @@ -103,7 +103,7 @@ impl<T> Map<int, T> for cat<T> { } } -impl<T> cat<T> { +pub impl<T> cat<T> { pure fn get(&self, k: &int) -> &self/T { match self.find(k) { Some(v) => { v } diff --git a/src/test/run-pass/class-implement-trait-cross-crate.rs b/src/test/run-pass/class-implement-trait-cross-crate.rs index aa7bb738bf5..aa77dbb62c0 100644 --- a/src/test/run-pass/class-implement-trait-cross-crate.rs +++ b/src/test/run-pass/class-implement-trait-cross-crate.rs @@ -20,7 +20,7 @@ struct cat { name : ~str, } -impl cat { +pub impl cat { fn eat(&mut self) -> bool { if self.how_hungry > 0 { error!("OM NOM NOM"); diff --git a/src/test/run-pass/class-implement-traits.rs b/src/test/run-pass/class-implement-traits.rs index bdc8f7568a1..896b139110f 100644 --- a/src/test/run-pass/class-implement-traits.rs +++ b/src/test/run-pass/class-implement-traits.rs @@ -32,7 +32,7 @@ priv impl cat { } } -impl cat { +pub impl cat { fn eat(&mut self) -> bool { if self.how_hungry > 0 { error!("OM NOM NOM"); diff --git a/src/test/run-pass/class-methods.rs b/src/test/run-pass/class-methods.rs index 1e41b60a822..f65bcf7be8e 100644 --- a/src/test/run-pass/class-methods.rs +++ b/src/test/run-pass/class-methods.rs @@ -14,7 +14,7 @@ struct cat { how_hungry : int, } -impl cat { +pub impl cat { fn speak(&mut self) { self.meows += 1u; } fn meow_count(&mut self) -> uint { self.meows } } diff --git a/src/test/run-pass/class-poly-methods.rs b/src/test/run-pass/class-poly-methods.rs index e81d07a783b..654260d8399 100644 --- a/src/test/run-pass/class-poly-methods.rs +++ b/src/test/run-pass/class-poly-methods.rs @@ -15,7 +15,7 @@ struct cat<U> { how_hungry : int, } -impl<U> cat<U> { +pub impl<U> cat<U> { fn speak<T>(&mut self, stuff: ~[T]) { self.meows += stuff.len(); } diff --git a/src/test/run-pass/class-separate-impl.rs b/src/test/run-pass/class-separate-impl.rs index 9c7d9ce7415..728deff8e2d 100644 --- a/src/test/run-pass/class-separate-impl.rs +++ b/src/test/run-pass/class-separate-impl.rs @@ -18,7 +18,7 @@ struct cat { name : ~str, } -impl cat { +pub impl cat { fn speak(&mut self) { self.meow(); } fn eat(&mut self) -> bool { diff --git a/src/test/run-pass/class-typarams.rs b/src/test/run-pass/class-typarams.rs index cbc69719caa..29354c54d8b 100644 --- a/src/test/run-pass/class-typarams.rs +++ b/src/test/run-pass/class-typarams.rs @@ -14,7 +14,7 @@ struct cat<U> { how_hungry : int, } -impl<U> cat<U> { +pub impl<U> cat<U> { fn speak(&mut self) { self.meows += 1u; } fn meow_count(&mut self) -> uint { self.meows } } diff --git a/src/test/run-pass/classes-simple-method.rs b/src/test/run-pass/classes-simple-method.rs index ac80ca9b9e9..505537af7a1 100644 --- a/src/test/run-pass/classes-simple-method.rs +++ b/src/test/run-pass/classes-simple-method.rs @@ -14,7 +14,7 @@ struct cat { how_hungry : int, } -impl cat { +pub impl cat { fn speak(&mut self) {} } diff --git a/src/test/run-pass/classes.rs b/src/test/run-pass/classes.rs index 552715dccb4..0d8d7fc37a9 100644 --- a/src/test/run-pass/classes.rs +++ b/src/test/run-pass/classes.rs @@ -15,7 +15,7 @@ struct cat { name : ~str, } -impl cat { +pub impl cat { fn speak(&mut self) { self.meow(); } fn eat(&mut self) -> bool { diff --git a/src/test/run-pass/coerce-reborrow-imm-ptr-rcvr.rs b/src/test/run-pass/coerce-reborrow-imm-ptr-rcvr.rs index 268e540c10e..35f963d8fb9 100644 --- a/src/test/run-pass/coerce-reborrow-imm-ptr-rcvr.rs +++ b/src/test/run-pass/coerce-reborrow-imm-ptr-rcvr.rs @@ -2,7 +2,7 @@ struct SpeechMaker { speeches: uint } -impl SpeechMaker { +pub impl SpeechMaker { pure fn how_many(&self) -> uint { self.speeches } } diff --git a/src/test/run-pass/coerce-reborrow-mut-ptr-rcvr.rs b/src/test/run-pass/coerce-reborrow-mut-ptr-rcvr.rs index a2ba4ddb827..fd47c262d6a 100644 --- a/src/test/run-pass/coerce-reborrow-mut-ptr-rcvr.rs +++ b/src/test/run-pass/coerce-reborrow-mut-ptr-rcvr.rs @@ -2,7 +2,7 @@ struct SpeechMaker { speeches: uint } -impl SpeechMaker { +pub impl SpeechMaker { fn talk(&mut self) { self.speeches += 1; } diff --git a/src/test/run-pass/const-enum-byref-self.rs b/src/test/run-pass/const-enum-byref-self.rs index 19311cb1732..57cfdd2f9d4 100644 --- a/src/test/run-pass/const-enum-byref-self.rs +++ b/src/test/run-pass/const-enum-byref-self.rs @@ -11,7 +11,7 @@ enum E { V, VV(int) } const C: E = V; -impl E { +pub impl E { fn method(&self) { match *self { V => {} diff --git a/src/test/run-pass/explicit-self-closures.rs b/src/test/run-pass/explicit-self-closures.rs index d40b2f72ae8..e019140d1a0 100644 --- a/src/test/run-pass/explicit-self-closures.rs +++ b/src/test/run-pass/explicit-self-closures.rs @@ -14,7 +14,7 @@ struct Box { x: uint } -impl Box { +pub impl Box { fn set_many(&mut self, xs: &[uint]) { for xs.each |x| { self.x = *x; } } diff --git a/src/test/run-pass/explicit-self-generic.rs b/src/test/run-pass/explicit-self-generic.rs index d03893367b4..5df155e4ad3 100644 --- a/src/test/run-pass/explicit-self-generic.rs +++ b/src/test/run-pass/explicit-self-generic.rs @@ -30,7 +30,7 @@ fn linear_map<K,V>() -> LinearMap<K,V> { size: 0}) } -impl<K,V> LinearMap<K,V> { +pub impl<K,V> LinearMap<K,V> { fn len(&mut self) -> uint { self.size } diff --git a/src/test/run-pass/explicit-self.rs b/src/test/run-pass/explicit-self.rs index 26e2023e89c..885eb9837a7 100644 --- a/src/test/run-pass/explicit-self.rs +++ b/src/test/run-pass/explicit-self.rs @@ -26,7 +26,7 @@ fn compute_area(shape: &shape) -> float { } } -impl shape { +pub impl shape { // self is in the implicit self region fn select<T>(&self, threshold: float, a: &r/T, b: &r/T) -> &r/T { @@ -54,7 +54,7 @@ fn thing(x: A) -> thing { } } -impl thing { +pub impl thing { fn foo(@self) -> int { *self.x.a } fn bar(~self) -> int { *self.x.a } fn quux(&self) -> int { *self.x.a } diff --git a/src/test/run-pass/impl-implicit-trait.rs b/src/test/run-pass/impl-implicit-trait.rs index 511529bbc8f..88e220670ba 100644 --- a/src/test/run-pass/impl-implicit-trait.rs +++ b/src/test/run-pass/impl-implicit-trait.rs @@ -13,7 +13,7 @@ enum option_<T> { some_(T), } -impl<T> option_<T> { +pub impl<T> option_<T> { fn foo() -> bool { true } } @@ -22,7 +22,7 @@ enum option__ { some__(int) } -impl option__ { +pub impl option__ { fn foo() -> bool { true } } diff --git a/src/test/run-pass/issue-2311-2.rs b/src/test/run-pass/issue-2311-2.rs index b4141b47b4d..f60db84eb86 100644 --- a/src/test/run-pass/issue-2311-2.rs +++ b/src/test/run-pass/issue-2311-2.rs @@ -13,7 +13,7 @@ struct foo<A> { x: A, } -impl<A:Copy> foo<A> { +pub impl<A:Copy> foo<A> { fn bar<B,C:clam<A>>(c: C) -> B { fail!(); } diff --git a/src/test/run-pass/issue-2312.rs b/src/test/run-pass/issue-2312.rs index 12e9157ba24..9e45a6b53c2 100644 --- a/src/test/run-pass/issue-2312.rs +++ b/src/test/run-pass/issue-2312.rs @@ -14,7 +14,7 @@ trait clam<A> { } enum foo = int; -impl foo { +pub impl foo { fn bar<B,C:clam<B>>(c: C) -> B { fail!(); } } diff --git a/src/test/run-pass/issue-2445-b.rs b/src/test/run-pass/issue-2445-b.rs index 9869b8d330b..73bf97ad7af 100644 --- a/src/test/run-pass/issue-2445-b.rs +++ b/src/test/run-pass/issue-2445-b.rs @@ -12,7 +12,7 @@ struct c1<T> { x: T, } -impl<T:Copy> c1<T> { +pub impl<T:Copy> c1<T> { fn f1(x: int) { } } @@ -23,7 +23,7 @@ fn c1<T:Copy>(x: T) -> c1<T> { } } -impl<T:Copy> c1<T> { +pub impl<T:Copy> c1<T> { fn f2(x: int) { } } diff --git a/src/test/run-pass/issue-2445.rs b/src/test/run-pass/issue-2445.rs index 4a085a1eb8a..973b8d85161 100644 --- a/src/test/run-pass/issue-2445.rs +++ b/src/test/run-pass/issue-2445.rs @@ -12,7 +12,7 @@ struct c1<T> { x: T, } -impl<T:Copy> c1<T> { +pub impl<T:Copy> c1<T> { fn f1(x: T) {} } @@ -22,7 +22,7 @@ fn c1<T:Copy>(x: T) -> c1<T> { } } -impl<T:Copy> c1<T> { +pub impl<T:Copy> c1<T> { fn f2(x: T) {} } diff --git a/src/test/run-pass/issue-2487-a.rs b/src/test/run-pass/issue-2487-a.rs index 198a8c900d7..33023db5323 100644 --- a/src/test/run-pass/issue-2487-a.rs +++ b/src/test/run-pass/issue-2487-a.rs @@ -17,7 +17,7 @@ impl Drop for socket { fn finalize(&self) {} } -impl socket { +pub impl socket { fn set_identity() { do closure { diff --git a/src/test/run-pass/issue-2502.rs b/src/test/run-pass/issue-2502.rs index 7696ec37217..57e5aa39864 100644 --- a/src/test/run-pass/issue-2502.rs +++ b/src/test/run-pass/issue-2502.rs @@ -12,7 +12,7 @@ struct font { fontbuf: &self/~[u8], } -impl font { +pub impl font { fn buf() -> &self/~[u8] { self.fontbuf } diff --git a/src/test/run-pass/issue-3220.rs b/src/test/run-pass/issue-3220.rs index ef65531e554..9ecc46c17ac 100644 --- a/src/test/run-pass/issue-3220.rs +++ b/src/test/run-pass/issue-3220.rs @@ -19,7 +19,7 @@ fn thing() -> thing { x: 0 } } -impl thing { fn f(self) {} } +pub impl thing { fn f(self) {} } pub fn main() { let z = thing(); diff --git a/src/test/run-pass/issue-3447.rs b/src/test/run-pass/issue-3447.rs index 0d1b0b9d002..2f7cb998e1a 100644 --- a/src/test/run-pass/issue-3447.rs +++ b/src/test/run-pass/issue-3447.rs @@ -13,7 +13,7 @@ struct list<T> { next: Option<@mut list<T>> } -impl<T> list<T>{ +pub impl<T> list<T>{ fn addEnd(&mut self, element: &self/T) { let newList = list { element: element, diff --git a/src/test/run-pass/issue-3860.rs b/src/test/run-pass/issue-3860.rs index fdc50220014..b113e902963 100644 --- a/src/test/run-pass/issue-3860.rs +++ b/src/test/run-pass/issue-3860.rs @@ -10,7 +10,7 @@ struct Foo { x: int } -impl Foo { +pub impl Foo { fn stuff(&mut self) -> &self/mut Foo { return self; } diff --git a/src/test/run-pass/issue-3904.rs b/src/test/run-pass/issue-3904.rs index 8f2b13b6eb0..1a09a8b860f 100644 --- a/src/test/run-pass/issue-3904.rs +++ b/src/test/run-pass/issue-3904.rs @@ -23,7 +23,7 @@ struct X { err: ErrPrinter } -impl X { +pub impl X { fn boom() { exit(self.err, "prog", "arg"); } diff --git a/src/test/run-pass/max-min-classes.rs b/src/test/run-pass/max-min-classes.rs index 762b89f5101..56c16d92874 100644 --- a/src/test/run-pass/max-min-classes.rs +++ b/src/test/run-pass/max-min-classes.rs @@ -17,7 +17,7 @@ struct Foo { y: int, } -impl Foo { +pub impl Foo { fn sum() -> int { self.x + self.y } diff --git a/src/test/run-pass/move-self.rs b/src/test/run-pass/move-self.rs index 37ce1bce9e6..d8464695728 100644 --- a/src/test/run-pass/move-self.rs +++ b/src/test/run-pass/move-self.rs @@ -2,7 +2,7 @@ struct S { x: ~str } -impl S { +pub impl S { fn foo(self) { self.bar(); } diff --git a/src/test/run-pass/nested-class.rs b/src/test/run-pass/nested-class.rs index 149e346bb47..2f2930dbab7 100644 --- a/src/test/run-pass/nested-class.rs +++ b/src/test/run-pass/nested-class.rs @@ -14,7 +14,7 @@ pub fn main() { i: int, } - impl b { + pub impl b { fn do_stuff() -> int { return 37; } } diff --git a/src/test/run-pass/operator-overloading-explicit-self.rs b/src/test/run-pass/operator-overloading-explicit-self.rs index 5a3ed4c6082..b56f7fa961e 100644 --- a/src/test/run-pass/operator-overloading-explicit-self.rs +++ b/src/test/run-pass/operator-overloading-explicit-self.rs @@ -12,7 +12,7 @@ struct S { x: int } -impl S { +pub impl S { pure fn add(&self, other: &S) -> S { S { x: self.x + other.x } } diff --git a/src/test/run-pass/private-class-field.rs b/src/test/run-pass/private-class-field.rs index 9cb86ffe837..0abb758bd7e 100644 --- a/src/test/run-pass/private-class-field.rs +++ b/src/test/run-pass/private-class-field.rs @@ -14,7 +14,7 @@ struct cat { how_hungry : int, } -impl cat { +pub impl cat { fn meow_count(&mut self) -> uint { self.meows } } diff --git a/src/test/run-pass/private-method.rs b/src/test/run-pass/private-method.rs index 432c189ae42..1fab77cb5c8 100644 --- a/src/test/run-pass/private-method.rs +++ b/src/test/run-pass/private-method.rs @@ -14,7 +14,7 @@ struct cat { how_hungry : int, } -impl cat { +pub impl cat { fn play(&mut self) { self.meows += 1u; self.nap(); diff --git a/src/test/run-pass/reflect-visit-data.rs b/src/test/run-pass/reflect-visit-data.rs index 27afde631b2..98e42bd7b4d 100644 --- a/src/test/run-pass/reflect-visit-data.rs +++ b/src/test/run-pass/reflect-visit-data.rs @@ -30,7 +30,7 @@ fn align(size: uint, align: uint) -> uint { enum ptr_visit_adaptor<V> = Inner<V>; -impl<V:TyVisitor + movable_ptr> ptr_visit_adaptor<V> { +pub impl<V:TyVisitor + movable_ptr> ptr_visit_adaptor<V> { #[inline(always)] fn bump(sz: uint) { @@ -478,7 +478,7 @@ struct Stuff { vals: ~[~str] } -impl my_visitor { +pub impl my_visitor { fn get<T>(f: fn(T)) { unsafe { f(*(self.ptr1 as *T)); diff --git a/src/test/run-pass/resource-destruct.rs b/src/test/run-pass/resource-destruct.rs index 3dc4ca7bd61..2b00aea2b4c 100644 --- a/src/test/run-pass/resource-destruct.rs +++ b/src/test/run-pass/resource-destruct.rs @@ -18,7 +18,7 @@ impl Drop for shrinky_pointer { } } -impl shrinky_pointer { +pub impl shrinky_pointer { fn look_at() -> int { return **(self.i); } } |
