]> git.lizzy.rs Git - rust.git/commitdiff
librustc: Mark all type implementations public. rs=impl-publicity
authorPatrick Walton <pcwalton@mimiga.net>
Wed, 27 Feb 2013 01:47:41 +0000 (17:47 -0800)
committerPatrick Walton <pcwalton@mimiga.net>
Thu, 28 Feb 2013 19:32:24 +0000 (11:32 -0800)
114 files changed:
src/libcore/cell.rs
src/libcore/comm.rs
src/libcore/condition.rs
src/libcore/dlist.rs
src/libcore/dvec.rs
src/libcore/mutable.rs
src/libcore/option.rs
src/libcore/path.rs
src/libcore/pipes.rs
src/libcore/private.rs
src/libcore/private/extfmt.rs
src/libcore/rand.rs
src/libcore/reflect.rs
src/libcore/repr.rs
src/libcore/result.rs
src/libcore/task/mod.rs
src/librustc/middle/astencode.rs
src/librustc/middle/borrowck/check_loans.rs
src/librustc/middle/borrowck/gather_loans.rs
src/librustc/middle/borrowck/loan.rs
src/librustc/middle/borrowck/mod.rs
src/librustc/middle/borrowck/preserve.rs
src/librustc/middle/lang_items.rs
src/librustc/middle/lint.rs
src/librustc/middle/liveness.rs
src/librustc/middle/mem_categorization.rs
src/librustc/middle/moves.rs
src/librustc/middle/trans/expr.rs
src/librustc/middle/ty.rs
src/librustc/middle/typeck/infer/coercion.rs
src/librustc/middle/typeck/infer/mod.rs
src/librustc/middle/typeck/infer/region_inference.rs
src/librustc/middle/typeck/infer/test.rs
src/librustdoc/doc.rs
src/librustdoc/sort_item_type_pass.rs
src/libstd/arc.rs
src/libstd/arena.rs
src/libstd/bitv.rs
src/libstd/deque.rs
src/libstd/ebml.rs
src/libstd/future.rs
src/libstd/net_tcp.rs
src/libstd/oldmap.rs
src/libstd/priority_queue.rs
src/libstd/sort.rs
src/libstd/sync.rs
src/libstd/time.rs
src/libstd/treemap.rs
src/libstd/workcache.rs
src/libsyntax/ast.rs
src/libsyntax/ext/deriving.rs
src/test/auxiliary/impl_privacy_xc_1.rs
src/test/auxiliary/issue_2472_b.rs
src/test/bench/core-set.rs
src/test/bench/noise.rs
src/test/compile-fail/assign-to-method.rs
src/test/compile-fail/borrowck-autoref-3261.rs
src/test/compile-fail/borrowck-call-method-from-mut-aliasable.rs
src/test/compile-fail/borrowck-insert-during-each.rs
src/test/compile-fail/borrowck-loan-rcvr-overloaded-op.rs
src/test/compile-fail/class-cast-to-trait.rs
src/test/compile-fail/issue-2356.rs
src/test/compile-fail/issue-2766-a.rs
src/test/compile-fail/issue-3021-b.rs
src/test/compile-fail/issue-3080.rs
src/test/compile-fail/issue-3311.rs
src/test/compile-fail/issue-3707.rs
src/test/compile-fail/issue-3763.rs
src/test/compile-fail/mutable-class-fields-2.rs
src/test/compile-fail/regions-addr-of-self.rs
src/test/compile-fail/regions-addr-of-upvar-self.rs
src/test/compile-fail/trait-or-new-type-instead.rs
src/test/compile-fail/use-after-move-self-based-on-type.rs
src/test/compile-fail/use-after-move-self.rs
src/test/run-pass/anon-trait-static-method.rs
src/test/run-pass/auto-ref-newtype.rs
src/test/run-pass/autoderef-and-borrow-method-receiver.rs
src/test/run-pass/borrowck-wg-borrow-mut-to-imm-3.rs
src/test/run-pass/class-cast-to-trait-multiple-types.rs
src/test/run-pass/class-cast-to-trait.rs
src/test/run-pass/class-impl-very-parameterized-trait.rs
src/test/run-pass/class-implement-trait-cross-crate.rs
src/test/run-pass/class-implement-traits.rs
src/test/run-pass/class-methods.rs
src/test/run-pass/class-poly-methods.rs
src/test/run-pass/class-separate-impl.rs
src/test/run-pass/class-typarams.rs
src/test/run-pass/classes-simple-method.rs
src/test/run-pass/classes.rs
src/test/run-pass/coerce-reborrow-imm-ptr-rcvr.rs
src/test/run-pass/coerce-reborrow-mut-ptr-rcvr.rs
src/test/run-pass/const-enum-byref-self.rs
src/test/run-pass/explicit-self-closures.rs
src/test/run-pass/explicit-self-generic.rs
src/test/run-pass/explicit-self.rs
src/test/run-pass/impl-implicit-trait.rs
src/test/run-pass/issue-2311-2.rs
src/test/run-pass/issue-2312.rs
src/test/run-pass/issue-2445-b.rs
src/test/run-pass/issue-2445.rs
src/test/run-pass/issue-2487-a.rs
src/test/run-pass/issue-2502.rs
src/test/run-pass/issue-3220.rs
src/test/run-pass/issue-3447.rs
src/test/run-pass/issue-3860.rs
src/test/run-pass/issue-3904.rs
src/test/run-pass/max-min-classes.rs
src/test/run-pass/move-self.rs
src/test/run-pass/nested-class.rs
src/test/run-pass/operator-overloading-explicit-self.rs
src/test/run-pass/private-class-field.rs
src/test/run-pass/private-method.rs
src/test/run-pass/reflect-visit-data.rs
src/test/run-pass/resource-destruct.rs

index 5887df6802f57502ecb705fe08a2d9e64c7d498c..6c35c62c3a7050aeba43782de025ed423065dfc4 100644 (file)
@@ -28,7 +28,7 @@ pub fn Cell<T>(value: T) -> Cell<T> {
     Cell { value: None }
 }
 
-impl<T> Cell<T> {
+pub impl<T> Cell<T> {
     /// Yields the value, failing if the cell is empty.
     fn take() -> T {
         if self.is_empty() {
index 7939644e51cb9259b160686ee960adfe65bf6672..da69cd984cd6fc7812552a2241fa29a45976ba38 100644 (file)
@@ -190,7 +190,7 @@ pub fn PortSet<T: Owned>() -> PortSet<T>{
     }
 }
 
-impl<T: Owned> PortSet<T> {
+pub impl<T: Owned> PortSet<T> {
 
     fn add(port: Port<T>) {
         self.ports.push(port)
@@ -323,12 +323,12 @@ pub fn oneshot<T: Owned>() -> (PortOne<T>, ChanOne<T>) {
     (port, chan)
 }
 
-impl<T: Owned> PortOne<T> {
+pub impl<T: Owned> PortOne<T> {
     fn recv(self) -> T { recv_one(self) }
     fn try_recv(self) -> Option<T> { try_recv_one(self) }
 }
 
-impl<T: Owned> ChanOne<T> {
+pub impl<T: Owned> ChanOne<T> {
     fn send(self, data: T) { send_one(self, data) }
     fn try_send(self, data: T) -> bool { try_send_one(self, data) }
 }
index a7c8c1f4d66001aed32f3947d9838f755d6e91b3..00048beae5acb831b01f959c49fc0682d370a73f 100644 (file)
@@ -25,7 +25,7 @@ pub struct Condition<T, U> {
     key: task::local_data::LocalDataKey<Handler<T, U>>
 }
 
-impl<T, U> Condition<T, U> {
+pub impl<T, U> Condition<T, U> {
     fn trap(&self, h: &self/fn(T) -> U) -> Trap/&self<T, U> {
         unsafe {
             let p : *RustClosure = ::cast::transmute(&h);
@@ -69,7 +69,7 @@ struct Trap<T, U> {
     handler: @Handler<T, U>
 }
 
-impl<T, U> Trap<T, U> {
+pub impl<T, U> Trap<T, U> {
     fn in<V>(&self, inner: &self/fn() -> V) -> V {
         unsafe {
             let _g = Guard { cond: self.cond };
index 3580736488926fc2d095eb0cafce3b5b1a671d83..f1f4e55866101b05284475fc77cc6d2505690d25 100644 (file)
@@ -62,7 +62,7 @@ pub struct DList<T> {
     }
 }
 
-impl<T> DListNode<T> {
+pub impl<T> DListNode<T> {
     /// Get the next node in the list, if there is one.
     pure fn next_link(@mut self) -> DListLink<T> {
         self.assert_links();
@@ -208,7 +208,7 @@ fn insert_right(@mut self,
     }
 }
 
-impl<T> DList<T> {
+pub impl<T> DList<T> {
     /// Get the size of the list. O(1).
     pure fn len(@mut self) -> uint { self.size }
     /// Returns true if the list is empty. O(1).
@@ -457,7 +457,7 @@ fn assert_consistent(@mut self) {
     }
 }
 
-impl<T:Copy> DList<T> {
+pub impl<T:Copy> DList<T> {
     /// Remove data from the head of the list. O(1).
     fn pop(@mut self) -> Option<T> {
         self.pop_n().map(|nobe| nobe.data)
index 9f2036c5f41a6b4b949c538c7b26966d1cff812c..6c7c195b9d3021467218d660c6ddb3f280a37340 100644 (file)
@@ -117,7 +117,7 @@ fn unwrap(self) -> ~[A] { unwrap(self) }
 // In theory, most everything should work with any A, but in practice
 // almost nothing works without the copy bound due to limitations
 // around closures.
-impl<A> DVec<A> {
+pub impl<A> DVec<A> {
     /// Reserves space for N elements
     fn reserve(count: uint) {
         vec::reserve(&mut self.data, count)
@@ -215,7 +215,7 @@ fn borrow_mut<R>(op: &fn(x: &mut [A]) -> R) -> R {
     }
 }
 
-impl<A:Copy> DVec<A> {
+pub impl<A:Copy> DVec<A> {
     /**
      * Append all elements of a vector to the end of the list
      *
index 1fb855520ba49d92d15b740c813fc3c4d25e8fb8..f888fbdb40cc6421e1bf33a16db0ea4828fd5191 100644 (file)
@@ -43,7 +43,7 @@ pub fn unwrap<T>(m: Mut<T>) -> T {
     value
 }
 
-impl<T> Data<T> {
+pub impl<T> Data<T> {
     fn borrow_mut<R>(op: &fn(t: &mut T) -> R) -> R {
         match self.mode {
             Immutable => fail!(fmt!("%? currently immutable",
index 12ed0df007621cd01245b4ab18ea845148b10062..53944c4c2c8252f378f1e13ffad85682075b53cb 100644 (file)
@@ -281,7 +281,7 @@ pub fn swap_unwrap<T>(opt: &mut Option<T>) -> T {
     }
 }
 
-impl<T> Option<T> {
+pub impl<T> Option<T> {
     /// Returns true if the option equals `none`
     #[inline(always)]
     pure fn is_none(&self) -> bool { is_none(self) }
@@ -393,7 +393,7 @@ fn swap_unwrap(&mut self) -> T { swap_unwrap(self) }
     pure fn expect(self, reason: &str) -> T { expect(self, reason) }
 }
 
-impl<T:Copy> Option<T> {
+pub impl<T:Copy> Option<T> {
     /**
     Gets the value out of an option
 
@@ -421,7 +421,7 @@ impl<T:Copy> Option<T> {
     }
 }
 
-impl<T:Copy + Zero> Option<T> {
+pub impl<T:Copy + Zero> Option<T> {
     #[inline(always)]
     pure fn get_or_zero(self) -> T { get_or_zero(self) }
 }
index 1753862649f57387072e06a6b25a9353e1597608..4e0e4e93cf5ae29a01f88b814c9dd95de1853d8a 100644 (file)
@@ -241,7 +241,7 @@ pub fn default_stat() -> libc::stat {
 }
 
 
-impl Path {
+pub impl Path {
     fn stat(&self) -> Option<libc::stat> {
         unsafe {
              do str::as_c_str(self.to_str()) |buf| {
@@ -290,7 +290,7 @@ fn get_mode(&self) -> Option<uint> {
 #[cfg(target_os = "freebsd")]
 #[cfg(target_os = "linux")]
 #[cfg(target_os = "macos")]
-impl Path {
+pub impl Path {
     fn get_atime(&self) -> Option<(i64, int)> {
         match self.stat() {
             None => None,
@@ -324,7 +324,7 @@ fn get_ctime(&self) -> Option<(i64, int)> {
 
 #[cfg(target_os = "freebsd")]
 #[cfg(target_os = "macos")]
-impl Path {
+pub impl Path {
     fn get_birthtime(&self) -> Option<(i64, int)> {
         match self.stat() {
             None => None,
@@ -337,7 +337,7 @@ fn get_birthtime(&self) -> Option<(i64, int)> {
 }
 
 #[cfg(target_os = "win32")]
-impl Path {
+pub impl Path {
     fn get_atime(&self) -> Option<(i64, int)> {
         match self.stat() {
             None => None,
index a0a29c6b5160193159a75024296f1d1ceda555e9..6389ec086159502778374c31e629d3e82d2c0148 100644 (file)
@@ -800,7 +800,7 @@ pub fn SendPacketBuffered<T,Tbuffer>(p: *Packet<T>)
     }
 }
 
-impl<T,Tbuffer> SendPacketBuffered<T,Tbuffer> {
+pub impl<T,Tbuffer> SendPacketBuffered<T,Tbuffer> {
     fn unwrap() -> *Packet<T> {
         let mut p = None;
         p <-> self.p;
@@ -857,7 +857,7 @@ fn finalize(&self) {
     }
 }
 
-impl<T:Owned,Tbuffer:Owned> RecvPacketBuffered<T, Tbuffer> {
+pub impl<T:Owned,Tbuffer:Owned> RecvPacketBuffered<T, Tbuffer> {
     fn unwrap() -> *Packet<T> {
         let mut p = None;
         p <-> self.p;
index e4fab18966cadd0b71387cb16634850dcc0c2026..7968fdce46e7a88df2084ffb1c73bd59efbe12a3 100644 (file)
@@ -335,7 +335,7 @@ fn LittleLock() -> LittleLock {
     }
 }
 
-impl LittleLock {
+pub impl LittleLock {
     #[inline(always)]
     unsafe fn lock<T>(f: fn() -> T) -> T {
         struct Unlock {
@@ -381,7 +381,7 @@ fn clone(&self) -> Exclusive<T> {
     }
 }
 
-impl<T:Owned> Exclusive<T> {
+pub impl<T:Owned> Exclusive<T> {
     // Exactly like std::arc::mutex_arc,access(), but with the little_lock
     // instead of a proper mutex. Same reason for being unsafe.
     //
index 36ea67ea6954e8ace732c3a65022a9bb9807b093..616d37a133a9f18af4e6b5fba03105a5754c3cc0 100644 (file)
@@ -142,7 +142,7 @@ struct Parsed<T> {
         next: uint
     }
 
-    impl<T> Parsed<T> {
+    pub impl<T> Parsed<T> {
         static pure fn new(val: T, next: uint) -> Parsed<T> {
             Parsed {val: val, next: next}
         }
index 15362f89e3fb63f176836597b42fe7fcc455861e..04a551740a80fb88a476ea87f1c9ba2d349a2050 100644 (file)
@@ -141,7 +141,7 @@ pub struct Weighted<T> {
 }
 
 /// Extension methods for random number generators
-impl Rng {
+pub impl Rng {
     /// Return a random value for a Rand type
     fn gen<T:Rand>() -> T {
         Rand::rand(self)
index ed7e485678e10dcefb9ada7362d21e332ebdc900..2a688482f6186f8e2bf84387b165fd513605d04a 100644 (file)
@@ -45,7 +45,7 @@ pub fn MovePtrAdaptor<V:TyVisitor + MovePtr>(v: V) -> MovePtrAdaptor<V> {
     MovePtrAdaptor { inner: v }
 }
 
-impl<V:TyVisitor + MovePtr> MovePtrAdaptor<V> {
+pub impl<V:TyVisitor + MovePtr> MovePtrAdaptor<V> {
     #[inline(always)]
     fn bump(sz: uint) {
       do self.inner.move_ptr() |p| {
index 4c3abb09756e99b05d625e8afb1ba0a6f85335b4..ab4bdec266cbf8850258be75f0b45112a126db97 100644 (file)
@@ -167,7 +167,7 @@ fn pop_ptr() {
     }
 }
 
-impl ReprVisitor {
+pub impl ReprVisitor {
 
     // Various helpers for the TyVisitor impl
 
index b03eaeab3e0cc510a082711a73d6c4a1344dbf47..ddcd1547841db5ae882b1735bde47563cfc28c6c 100644 (file)
@@ -228,7 +228,7 @@ pub enum Result<T, U> {
     }
 }
 
-impl<T, E> Result<T, E> {
+pub impl<T, E> Result<T, E> {
     #[inline(always)]
     pure fn get_ref(&self) -> &self/T { get_ref(self) }
 
@@ -261,7 +261,7 @@ impl<T, E> Result<T, E> {
     }
 }
 
-impl<T:Copy,E> Result<T, E> {
+pub impl<T:Copy,E> Result<T, E> {
     #[inline(always)]
     pure fn get(&self) -> T { get(self) }
 
@@ -271,7 +271,7 @@ impl<T:Copy,E> Result<T, E> {
     }
 }
 
-impl<T, E: Copy> Result<T, E> {
+pub impl<T, E: Copy> Result<T, E> {
     #[inline(always)]
     pure fn get_err(&self) -> E { get_err(self) }
 
index 2a640e4bf8cf731de5d4909e6caf99a41ac89044..49507897392de428f9dd0ecdb80dd36d9f40a883 100644 (file)
@@ -232,7 +232,7 @@ fn consume() -> TaskBuilder {
     }
 }
 
-impl TaskBuilder {
+pub impl TaskBuilder {
     /**
      * Decouple the child task's failure from the parent's. If either fails,
      * the other will not be killed.
index 58433cec2725dd4d44f49619944df438c6019a14..d6af3873999202be3085c15f9fa0941335962baf 100644 (file)
@@ -167,7 +167,7 @@ fn reserve_id_range(sess: Session,
     ast_util::id_range { min: to_id_min, max: to_id_min }
 }
 
-impl ExtendedDecodeContext {
+pub impl ExtendedDecodeContext {
     fn tr_id(&self, id: ast::node_id) -> ast::node_id {
         /*!
          *
index afefec00c5040a1ad81a3533302f08b21f57eb48..f1e52d00beed95119ea79b1b4c22b7b6a974748d 100644 (file)
@@ -89,7 +89,7 @@ enum assignment_type {
     at_swap
 }
 
-impl assignment_type {
+pub impl assignment_type {
     fn checked_by_liveness(&self) -> bool {
         // the liveness pass guarantees that immutable local variables
         // are only assigned once; but it doesn't consider &mut
@@ -106,7 +106,7 @@ fn ing_form(&self, desc: ~str) -> ~str {
     }
 }
 
-impl CheckLoanCtxt {
+pub impl CheckLoanCtxt {
     fn tcx(@mut self) -> ty::ctxt { self.bccx.tcx }
 
     fn purity(@mut self, scope_id: ast::node_id) -> Option<purity_cause> {
index 546e9359a32d9da7b4fc2e295b2acf17068f29be..c997b4a6b5f43e665c8361e3b5e88a06573479f1 100644 (file)
@@ -289,7 +289,7 @@ fn req_loans_in_expr(ex: @ast::expr,
     self.root_ub = old_root_ub;
 }
 
-impl GatherLoanCtxt {
+pub impl GatherLoanCtxt {
     fn tcx(@mut self) -> ty::ctxt { self.bccx.tcx }
 
     fn guarantee_adjustments(@mut self,
index c39f2455c2f8fd25010d2f5a867d647d21bba04e..e095c970931316c40cc67e9ee61436eed31c2fe6 100644 (file)
@@ -87,7 +87,7 @@ struct LoanContext {
     loans: ~[Loan]
 }
 
-impl LoanContext {
+pub impl LoanContext {
     fn tcx(&self) -> ty::ctxt { self.bccx.tcx }
 
     fn loan(&mut self,
index eb2a93d86f9a465e9473941af66576657f22307b..b432d5a399adbba94e019d07e09d20ed7961d9fb 100644 (file)
@@ -433,7 +433,7 @@ pub fn save_and_restore_managed<T:Copy,U>(save_and_restore_t: @mut T,
     u
 }
 
-impl LoanKind {
+pub impl LoanKind {
     fn is_freeze(&self) -> bool {
         match *self {
             TotalFreeze | PartialFreeze => true,
index a123793e20b29722d36b73973051278d0664d27a..aabcd7a2fe5b153ff0b9df0330241abf5c4fc61b 100644 (file)
@@ -35,7 +35,7 @@ pub enum PreserveCondition {
     PcIfPure(bckerr)
 }
 
-impl PreserveCondition {
+pub impl PreserveCondition {
     // combines two preservation conditions such that if either of
     // them requires purity, the result requires purity
     fn combine(&self, pc: PreserveCondition) -> PreserveCondition {
@@ -46,7 +46,7 @@ fn combine(&self, pc: PreserveCondition) -> PreserveCondition {
     }
 }
 
-impl BorrowckCtxt {
+pub impl BorrowckCtxt {
     fn preserve(&self,
                 cmt: cmt,
                 scope_region: ty::Region,
@@ -80,7 +80,7 @@ struct PreserveCtxt {
     root_managed_data: bool
 }
 
-impl PreserveCtxt {
+pub impl PreserveCtxt {
     fn tcx(&self) -> ty::ctxt { self.bccx.tcx }
 
     fn preserve(&self, cmt: cmt) -> bckres<PreserveCondition> {
index 84871f7496472b7dd02f5ae839a8b01b172e1aa0..16f1d36e05c7c406e5cb8073170c53d63cd3bd45 100644 (file)
@@ -322,7 +322,7 @@ struct LanguageItemCollector {
     item_refs: HashMap<@~str, uint>,
 }
 
-impl LanguageItemCollector {
+pub impl LanguageItemCollector {
     fn match_and_collect_meta_item(&self, item_def_id: def_id,
                                    meta_item: meta_item) {
         match meta_item.node {
index eb418d0cd5acb1e3d5ba5cda0189057a50b36ee7..b14245afa9a19bac97a4a814f37d622c4f326d9e 100644 (file)
@@ -331,7 +331,7 @@ struct Context {
     sess: Session
 }
 
-impl Context {
+pub impl Context {
     fn get_level(&self, lint: lint) -> level {
         get_lint_level(self.curr, lint)
     }
index 96aa41f78091359e19995f822199b5537a35c24d..3753c93f13ade1aa30670404854333927d5ca79f 100644 (file)
@@ -254,7 +254,7 @@ impl to_str::ToStr for Variable {
 // variable must not be assigned if there is some successor
 // assignment.  And so forth.
 
-impl LiveNode {
+pub impl LiveNode {
     pure fn is_valid(&self) -> bool { **self != uint::max_value }
 }
 
@@ -334,7 +334,7 @@ fn IrMaps(tcx: ty::ctxt,
     }
 }
 
-impl IrMaps {
+pub impl IrMaps {
     fn add_live_node(&mut self, lnk: LiveNodeKind) -> LiveNode {
         let ln = LiveNode(self.num_live_nodes);
         self.lnks.push(lnk);
@@ -693,7 +693,7 @@ fn Liveness(ir: @mut IrMaps, specials: Specials) -> Liveness {
     }
 }
 
-impl Liveness {
+pub impl Liveness {
     fn live_node(&self, node_id: node_id, span: span) -> LiveNode {
         match self.ir.live_node_map.find(&node_id) {
           Some(ln) => ln,
@@ -1649,7 +1649,7 @@ enum ReadKind {
     PartiallyMovedValue
 }
 
-impl @Liveness {
+pub impl @Liveness {
     fn check_ret(&self, id: node_id, sp: span, _fk: visit::fn_kind,
                  entry_ln: LiveNode) {
         if self.live_on_entry(entry_ln, self.s.no_ret_var).is_some() {
index 3f8ee61e8412dea9ab487a6a0ae18eb0527eb205..227d262a79e1673b6f7d2647c89c2f57871d0c45 100644 (file)
@@ -312,7 +312,7 @@ impl ToStr for MutabilityCategory {
     }
 }
 
-impl MutabilityCategory {
+pub impl MutabilityCategory {
     static fn from_mutbl(&self, m: ast::mutability) -> MutabilityCategory {
         match m {
             m_imm => McImmutable,
index b23066c1d96921504dcec9d4ad12cc6572864fc5..d5adfee65af9f64d50e7b58272cb07af8f838230 100644 (file)
@@ -301,7 +301,7 @@ fn compute_modes_for_expr(expr: @expr,
     cx.consume_expr(expr, v);
 }
 
-impl UseMode {
+pub impl UseMode {
     fn component_mode(&self, expr: @expr) -> UseMode {
         /*!
          *
@@ -316,7 +316,7 @@ fn component_mode(&self, expr: @expr) -> UseMode {
     }
 }
 
-impl VisitContext {
+pub impl VisitContext {
     fn consume_exprs(&self,
                      exprs: &[@expr],
                      visitor: vt<VisitContext>)
index 6226e83d046b3eb85ec845dc2ab92808911aab7a..0dd30af4b71930a64741187d3a60adf20a618707 100644 (file)
@@ -154,7 +154,7 @@ pub enum Dest {
     Ignore,
 }
 
-impl Dest {
+pub impl Dest {
     fn to_str(&self, ccx: @CrateContext) -> ~str {
         match *self {
             SaveIn(v) => fmt!("SaveIn(%s)", val_str(ccx.tn, v)),
index 8431426fc1b5a69653b708614dbe0ea4fd192a0a..7105017cd88d2d9a1f88d570614602a749dad0b9 100644 (file)
@@ -3714,7 +3714,7 @@ pub enum DtorKind {
     TraitDtor(def_id)
 }
 
-impl DtorKind {
+pub impl DtorKind {
     pure fn is_not_present(&const self) -> bool {
         match *self {
             NoDtor => true,
index 5d291fdde77b386a43f2094c529adf32a8df9470..6ad58bc5d4f437e1520997882580a3242b7c6710 100644 (file)
@@ -87,7 +87,7 @@ fn foo<A>(a: A, b: A) { ... }
 // function.
 pub enum Coerce = CombineFields;
 
-impl Coerce {
+pub impl Coerce {
     fn tys(&self, a: ty::t, b: ty::t) -> CoerceResult {
         debug!("Coerce.tys(%s => %s)",
                a.inf_str(self.infcx),
index 8bb1f2f47e5e4820a037a97690f16e80254e374d..aff2d599a0ef17fb441712f07586a5de13b1978e 100644 (file)
@@ -551,7 +551,7 @@ struct Snapshot {
     region_vars_snapshot: uint,
 }
 
-impl @mut InferCtxt {
+pub impl @mut InferCtxt {
     fn combine_fields(&self, a_is_expected: bool,
                       span: span) -> CombineFields {
         CombineFields {infcx: *self,
@@ -643,7 +643,7 @@ fn next_simple_var<V:Copy,T:Copy>(
     return id;
 }
 
-impl @mut InferCtxt {
+pub impl @mut InferCtxt {
     fn next_ty_var_id(&self) -> TyVid {
         let id = self.ty_var_counter;
         self.ty_var_counter += 1;
index ee598686652522f070565cb2ece010de590fbd4f..d016a6f790a60764e76e80aa2df75fc16227bd71 100644 (file)
@@ -1218,7 +1218,7 @@ fn TwoRegionsMap() -> TwoRegionsMap {
     return HashMap();
 }
 
-impl RegionVarBindings {
+pub impl RegionVarBindings {
     fn infer_variable_values(&mut self) -> ~[GraphNodeValue] {
         let mut graph = self.construct_graph();
         self.expansion(&mut graph);
index 27355da4b9aeea129eaaf6edbd22135bb17ed816..9701e370ca8ce310986cd8488693b10f214ef831 100644 (file)
@@ -79,7 +79,7 @@ fn setup_env(test_name: &str, source_string: &str) -> Env {
                 err_messages: messages};
 }
 
-impl Env {
+pub impl Env {
     fn create_region_hierarchy(&self, rh: &RH) {
         for rh.sub.each |child_rh| {
             self.create_region_hierarchy(child_rh);
index 40617e13b8d5e8539b6b36aeddd2fbd9ae521a6e..f7de1997d537383f04ef3a9c83912dcfccd87993 100644 (file)
@@ -174,7 +174,7 @@ pub struct IndexEntry {
     link: ~str
 }
 
-impl Doc {
+pub impl Doc {
     fn CrateDoc(&self) -> CrateDoc {
         option::get(vec::foldl(None, self.pages, |_m, page| {
             match copy *page {
@@ -190,7 +190,7 @@ fn cratemod(&self) -> ModDoc {
 }
 
 /// Some helper methods on ModDoc, mostly for testing
-impl ModDoc {
+pub impl ModDoc {
     fn mods(&self) -> ~[ModDoc] {
         do vec::filter_mapped(self.items) |itemtag| {
             match copy *itemtag {
index 646dc12d336e9941d05e0064c4777d10958a61c4..1a370947d6980b88c978e3b01a7ece7510e0bb93 100644 (file)
@@ -51,7 +51,7 @@ fn test() {
          fn ifn() { } \
          enum ienum { ivar } \
          trait itrait { fn a(); } \
-         impl int { fn a() { } } \
+         pub impl int { fn a() { } } \
          type itype = int; \
          struct istruct { f: () }";
     do astsrv::from_str(source) |srv| {
index f258e649122bdb17a8d778b3d5e9432bee1a9c73..1e2abbe028746e66d192b351f6a3c3609e6f6620 100644 (file)
@@ -30,7 +30,7 @@
 /// As sync::condvar, a mechanism for unlock-and-descheduling and signalling.
 pub struct Condvar { is_mutex: bool, failed: &mut bool, cond: &sync::Condvar }
 
-impl &Condvar {
+pub impl &Condvar {
     /// Atomically exit the associated ARC and block until a signal is sent.
     #[inline(always)]
     fn wait() { self.wait_on(0) }
@@ -158,7 +158,7 @@ fn clone(&self) -> MutexARC<T> {
     }
 }
 
-impl<T:Owned> &MutexARC<T> {
+pub impl<T:Owned> &MutexARC<T> {
 
     /**
      * Access the underlying mutable data with mutual exclusion from other
@@ -301,7 +301,7 @@ pub fn rw_arc_with_condvars<T:Const + Owned>(
     RWARC { x: unsafe { shared_mutable_state(data) }, cant_nest: () }
 }
 
-impl<T:Const + Owned> RWARC<T> {
+pub impl<T:Const + Owned> RWARC<T> {
     /// Duplicate a rwlock-protected ARC, as arc::clone.
     fn clone(&self) -> RWARC<T> {
         RWARC { x: unsafe { clone_shared_mutable_state(&self.x) },
@@ -310,7 +310,7 @@ fn clone(&self) -> RWARC<T> {
 
 }
 
-impl<T:Const + Owned> &RWARC<T> {
+pub impl<T:Const + Owned> &RWARC<T> {
     /**
      * Access the underlying data mutably. Locks the rwlock in write mode;
      * other readers and writers will block.
@@ -445,7 +445,7 @@ pub enum RWWriteMode<T> =
 /// The "read permission" token used for RWARC.write_downgrade().
 pub enum RWReadMode<T> = (&T, sync::RWlockReadMode);
 
-impl<T:Const + Owned> &RWWriteMode<T> {
+pub impl<T:Const + Owned> &RWWriteMode<T> {
     /// Access the pre-downgrade RWARC in write mode.
     fn write<U>(blk: fn(x: &mut T) -> U) -> U {
         match *self {
@@ -475,7 +475,7 @@ fn write_cond<U>(blk: fn(x: &x/mut T, c: &c/Condvar) -> U) -> U {
     }
 }
 
-impl<T:Const + Owned> &RWReadMode<T> {
+pub impl<T:Const + Owned> &RWReadMode<T> {
     /// Access the post-downgrade rwlock in read mode.
     fn read<U>(blk: fn(x: &T) -> U) -> U {
         match *self {
index 177932aa072a167629147efd3291d7afda440f58..a30ee94a42b0fcd1702d642fbb131931a4c4b9ea 100644 (file)
@@ -161,7 +161,7 @@ unsafe fn un_bitpack_tydesc_ptr(p: uint) -> (*TypeDesc, bool) {
     (reinterpret_cast(&(p & !1)), p & 1 == 1)
 }
 
-impl &Arena {
+pub impl &Arena {
     // Functions for the POD part of the arena
     fn alloc_pod_grow(n_bytes: uint, align: uint) -> *u8 {
         // Allocate a new chunk.
index 30d7b825add4a7f830fd3acbb80458a2b21aab99..cf278b07c9d9898afaa0e88b2f1cb41577493e4d 100644 (file)
@@ -27,7 +27,7 @@ fn small_mask(nbits: uint) -> uint {
     (1 << nbits) - 1
 }
 
-impl SmallBitv {
+pub impl SmallBitv {
     static fn new(bits: uint) -> SmallBitv {
         SmallBitv {bits: bits}
     }
@@ -124,7 +124,7 @@ fn big_mask(nbits: uint, elem: uint) -> uint {
     }
 }
 
-impl BigBitv {
+pub impl BigBitv {
     static fn new(storage: ~[uint]) -> BigBitv {
         BigBitv {storage: storage}
     }
@@ -256,7 +256,7 @@ fn do_op(&mut self, op: Op, other: &Bitv) -> bool {
 
 }
 
-impl Bitv {
+pub impl Bitv {
     static fn new(nbits: uint, init: bool) -> Bitv {
         let rep = if nbits <= uint::bits {
             Small(~SmallBitv::new(if init {!0} else {0}))
@@ -591,7 +591,7 @@ pub struct BitvSet {
     priv bitv: BigBitv
 }
 
-impl BitvSet {
+pub impl BitvSet {
     /// Creates a new bit vector set with initially no contents
     static fn new() -> BitvSet {
         BitvSet{ size: 0, bitv: BigBitv::new(~[0]) }
index 0ac76cefd6b36480cb47cbcbfce86e08b3f0f8e0..4d8c60a6614bc3074f8961e20768b3d192860996 100644 (file)
@@ -37,7 +37,7 @@ fn clear(&mut self) {
     }
 }
 
-impl<T> Deque<T> {
+pub impl<T> Deque<T> {
     static pure fn new() -> Deque<T> {
         Deque{nelts: 0, lo: 0, hi: 0,
               elts: vec::from_fn(initial_capacity, |_| None)}
index 84df1785503dcac42fde4959f8d94a1f31da1c1f..7d04f6760793ee3759df174030e7cb5f34dfeda5 100644 (file)
@@ -279,7 +279,7 @@ fn _next_uint(exp_tag: EbmlEncoderTag) -> uint {
         }
     }
 
-    impl Decoder {
+    pub impl Decoder {
         fn read_opaque<R>(&self, op: fn(Doc) -> R) -> R {
             do self.push_doc(self.next_doc(EsOpaque)) {
                 op(copy self.parent)
@@ -451,7 +451,7 @@ pub fn Encoder(w: io::Writer) -> Encoder {
     }
 
     // FIXME (#2741): Provide a function to write the standard ebml header.
-    impl Encoder {
+    pub impl Encoder {
         fn start_tag(tag_id: uint) {
             debug!("Start tag %u", tag_id);
 
@@ -571,7 +571,7 @@ fn _emit_label(label: &str) {
         }
     }
 
-    impl Encoder {
+    pub impl Encoder {
         fn emit_opaque(&self, f: fn()) {
             do self.wr_tag(EsOpaque as uint) {
                 f()
index 7f48466ed0a87a556f36db459aee11a2c868baef..b9c7c9f3a1386c3ca7b3b6f6037f45d21ec97628 100644 (file)
@@ -49,14 +49,14 @@ fn finalize(&self) {}
 }
 
 /// Methods on the `future` type
-impl<A:Copy> Future<A> {
+pub impl<A:Copy> Future<A> {
     fn get() -> A {
         //! Get the value of the future
         *(self.get_ref())
     }
 }
 
-impl<A> Future<A> {
+pub impl<A> Future<A> {
 
     pure fn get_ref(&self) -> &self/A {
         /*!
index 8835cdfb105eb57cc5e91e7fcb217bb865d7315e..dcbf7e60d8956072c959f704ea7fd2a5f9b4378c 100644 (file)
@@ -820,7 +820,7 @@ pub fn socket_buf(sock: TcpSocket) -> TcpSocketBuf {
 }
 
 /// Convenience methods extending `net::tcp::tcp_socket`
-impl TcpSocket {
+pub impl TcpSocket {
     pub fn read_start() -> result::Result<@Port<
         result::Result<~[u8], TcpErrData>>, TcpErrData> {
         read_start(&self)
index 53692cd3be5706bcfeffda5862935e065c866e33..c1227f6b077b255f68d0fe068acf9a0fac6e79c1 100644 (file)
@@ -168,7 +168,7 @@ fn clear(&mut self) {
         }
     }
 
-    impl<K:Eq + IterBytes + Hash,V> T<K, V> {
+    pub impl<K:Eq + IterBytes + Hash,V> T<K, V> {
         pure fn contains_key(&self, k: &K) -> bool {
             let hash = k.hash_keyed(0,0) as uint;
             match self.search_tbl(k, hash) {
@@ -252,7 +252,7 @@ fn remove(k: &K) -> bool {
         }
     }
 
-    impl<K:Eq + IterBytes + Hash + Copy,V:Copy> T<K, V> {
+    pub impl<K:Eq + IterBytes + Hash + Copy,V:Copy> T<K, V> {
         pure fn find(&self, k: &K) -> Option<V> {
             match self.search_tbl(k, k.hash_keyed(0,0) as uint) {
               NotFound => None,
@@ -325,7 +325,7 @@ fn update(key: K, newval: V, ff: fn(V, V) -> V) -> bool {
         }
     }
 
-    impl<K:Eq + IterBytes + Hash + Copy + ToStr,V:ToStr + Copy> T<K, V> {
+    pub impl<K:Eq + IterBytes + Hash + Copy + ToStr,V:ToStr + Copy> T<K, V> {
         fn to_writer(wr: io::Writer) {
             if self.count == 0u {
                 wr.write_str(~"{}");
index f642bf52f659ab718930a6e093236ea71b105ec0..4b92bd7543a7d1c84adab51f5b5b05da4b4961b7 100644 (file)
@@ -48,7 +48,7 @@ impl<T:Ord> Mutable for PriorityQueue<T> {
     fn clear(&mut self) { self.data.truncate(0) }
 }
 
-impl <T:Ord> PriorityQueue<T> {
+pub impl <T:Ord> PriorityQueue<T> {
     /// Returns the greatest item in the queue - fails if empty
     pure fn top(&self) -> &self/T { &self.data[0] }
 
index 75f38da5a19a1730f45e050eafa0afc05d7f6221..43fab9df1631e953626f119b060b2c360efe683a 100644 (file)
@@ -404,7 +404,7 @@ fn MergeState<T>() -> MergeState<T> {
     }
 }
 
-impl<T:Copy + Ord> MergeState<T> {
+pub impl<T:Copy + Ord> MergeState<T> {
     fn push_run(&self, run_base: uint, run_len: uint) {
         let tmp = RunState{base: run_base, len: run_len};
         self.runs.push(tmp);
index 1ff51e8bff0307d09a9f5f94cf71467fa16e1dde..22325e6a83c6d96ff3398e6cabbda661041e0558 100644 (file)
@@ -100,7 +100,7 @@ fn new_sem_and_signal(count: int, num_condvars: uint)
 }
 
 #[doc(hidden)]
-impl<Q:Owned> &Sem<Q> {
+pub impl<Q:Owned> &Sem<Q> {
     fn acquire() {
         let mut waiter_nobe = None;
         unsafe {
@@ -136,7 +136,7 @@ fn release() {
 }
 // FIXME(#3154) move both copies of this into Sem<Q>, and unify the 2 structs
 #[doc(hidden)]
-impl &Sem<()> {
+pub impl &Sem<()> {
     fn access<U>(blk: fn() -> U) -> U {
         let mut release = None;
         unsafe {
@@ -149,7 +149,7 @@ fn access<U>(blk: fn() -> U) -> U {
     }
 }
 #[doc(hidden)]
-impl &Sem<~[Waitqueue]> {
+pub impl &Sem<~[Waitqueue]> {
     fn access<U>(blk: fn() -> U) -> U {
         let mut release = None;
         unsafe {
@@ -192,7 +192,7 @@ pub struct Condvar { priv sem: &Sem<~[Waitqueue]> }
 
 impl Drop for Condvar { fn finalize(&self) {} }
 
-impl &Condvar {
+pub impl &Condvar {
     /**
      * Atomically drop the associated lock, and block until a signal is sent.
      *
@@ -344,7 +344,7 @@ fn check_cvar_bounds<U>(out_of_bounds: Option<uint>, id: uint, act: &str,
 }
 
 #[doc(hidden)]
-impl &Sem<~[Waitqueue]> {
+pub impl &Sem<~[Waitqueue]> {
     // The only other place that condvars get built is rwlock_write_mode.
     fn access_cond<U>(blk: fn(c: &Condvar) -> U) -> U {
         do self.access { blk(&Condvar { sem: self }) }
@@ -370,7 +370,7 @@ fn clone(&self) -> Semaphore {
     }
 }
 
-impl &Semaphore {
+pub impl &Semaphore {
     /**
      * Acquire a resource represented by the semaphore. Blocks if necessary
      * until resource(s) become available.
@@ -418,7 +418,7 @@ impl Clone for Mutex {
     fn clone(&self) -> Mutex { Mutex { sem: Sem((*self.sem).clone()) } }
 }
 
-impl &Mutex {
+pub impl &Mutex {
     /// Run a function with ownership of the mutex.
     fn lock<U>(blk: fn() -> U) -> U { (&self.sem).access(blk) }
 
@@ -467,7 +467,7 @@ pub fn rwlock_with_condvars(num_condvars: uint) -> RWlock {
                                              read_count: 0 }) }
 }
 
-impl &RWlock {
+pub impl &RWlock {
     /// Create a new handle to the rwlock.
     fn clone() -> RWlock {
         RWlock { order_lock:  (&(self.order_lock)).clone(),
@@ -688,7 +688,7 @@ impl Drop for RWlockWriteMode { fn finalize(&self) {} }
 pub struct RWlockReadMode  { priv lock: &RWlock }
 impl Drop for RWlockReadMode { fn finalize(&self) {} }
 
-impl &RWlockWriteMode {
+pub impl &RWlockWriteMode {
     /// Access the pre-downgrade rwlock in write mode.
     fn write<U>(blk: fn() -> U) -> U { blk() }
     /// Access the pre-downgrade rwlock in write mode with a condvar.
@@ -696,7 +696,7 @@ fn write_cond<U>(blk: fn(c: &Condvar) -> U) -> U {
         blk(&Condvar { sem: &self.lock.access_lock })
     }
 }
-impl &RWlockReadMode {
+pub impl &RWlockReadMode {
     /// Access the post-downgrade rwlock in read mode.
     fn read<U>(blk: fn() -> U) -> U { blk() }
 }
index c8379d3ef4444fa95e4f4bfd8d1209ba31a1485f..15dea83815b2a49fefaf13e8eb43ecfbfdfec8ec 100644 (file)
@@ -47,7 +47,7 @@ pub struct Timespec { sec: i64, nsec: i32 }
  * -1.2 seconds before the epoch is represented by `Timespec { sec: -2_i64,
  * nsec: 800_000_000_i32 }`.
  */
-impl Timespec {
+pub impl Timespec {
     static pure fn new(sec: i64, nsec: i32) -> Timespec {
         assert nsec >= 0 && nsec < NSEC_PER_SEC;
         Timespec { sec: sec, nsec: nsec }
@@ -208,7 +208,7 @@ pub fn now() -> Tm {
     unsafe { do_strftime(format, tm) }
 }
 
-impl Tm {
+pub impl Tm {
     /// Convert time to the seconds from January 1, 1970
     fn to_timespec() -> Timespec {
         unsafe {
index 0e593ba42d12951ac6ebe5f9f1facbf95ed4f725..cf863217deb1a6054f26ef10034f4e35471962e4 100644 (file)
@@ -177,7 +177,7 @@ fn remove(&mut self, key: &K) -> bool {
     }
 }
 
-impl <K:Ord,V> TreeMap<K, V> {
+pub impl <K:Ord,V> TreeMap<K, V> {
     /// Create an empty TreeMap
     static pure fn new() -> TreeMap<K, V> { TreeMap{root: None, length: 0} }
 
@@ -208,7 +208,7 @@ pub struct TreeMapIterator<K, V> {
 /// tuple with a reference to the key and value. If there are no
 /// more nodes, return `None`.
 fn map_next<K: Ord, V>(iter: &mut TreeMapIterator/&r<K, V>)
- -> Option<(&r/K, &r/V)> {
                   -> Option<(&r/K, &r/V)> {
     while !iter.stack.is_empty() || iter.node.is_some() {
         match *iter.node {
           Some(ref x) => {
@@ -480,7 +480,7 @@ fn remove(&mut self, value: &T) -> bool { self.map.remove(value) }
     }
 }
 
-impl <T:Ord> TreeSet<T> {
+pub impl <T:Ord> TreeSet<T> {
     /// Create an empty TreeSet
     static pure fn new() -> TreeSet<T> { TreeSet{map: TreeMap::new()} }
 
@@ -518,7 +518,7 @@ struct TreeNode<K, V> {
     level: uint
 }
 
-impl <K:Ord,V> TreeNode<K, V> {
+pub impl <K:Ord,V> TreeNode<K, V> {
     #[inline(always)]
     static pure fn new(key: K, value: V) -> TreeNode<K, V> {
         TreeNode{key: key, value: value, left: None, right: None, level: 1}
index c85aa78d9834a9df6a3982b7439e4801b6f9d6fa..592ac40e0824f3c7eb6bc2edd8e879d3ef7b8af7 100644 (file)
@@ -132,7 +132,7 @@ impl cmp::Ord for WorkKey {
     }
 }
 
-impl WorkKey {
+pub impl WorkKey {
     static fn new(kind: &str, name: &str) -> WorkKey {
     WorkKey { kind: kind.to_owned(), name: name.to_owned() }
     }
@@ -168,7 +168,7 @@ struct Database {
     mut db_dirty: bool
 }
 
-impl Database {
+pub impl Database {
     fn prepare(&mut self, fn_name: &str,
                declared_inputs: &WorkMap) -> Option<(WorkMap, WorkMap, ~str)>
     {
@@ -199,7 +199,7 @@ struct Logger {
     a: ()
 }
 
-impl Logger {
+pub impl Logger {
     fn info(i: &str) {
         io::println(~"workcache: " + i.to_owned());
     }
@@ -254,7 +254,7 @@ fn digest_file(path: &Path) -> ~str {
     sha.result_str()
 }
 
-impl Context {
+pub impl Context {
 
     static fn new(db: @Mut<Database>,
                   lg: @Mut<Logger>,
@@ -356,7 +356,7 @@ fn exec<T:Owned + Encodable<json::Encoder> + Decodable<json::Decoder>>(
     }
 }
 
-impl<T:Owned + Encodable<json::Encoder> + Decodable<json::Decoder>> Work<T> {
+pub impl<T:Owned+Encodable<json::Encoder>+Decodable<json::Decoder>> Work<T> {
     static fn new(p: @Mut<Prep>, e: Either<T,PortOne<(Exec,T)>>) -> Work<T> {
         Work { prep: p, res: Some(e) }
     }
index f97244c477b7e9f7f83a4959499196dfc05bf49e..c6994125b26133708540acf8ad483ba5d280b1a9 100644 (file)
@@ -162,7 +162,7 @@ pub struct Generics {
     ty_params: OptVec<TyParam>
 }
 
-impl Generics {
+pub impl Generics {
     fn is_empty(&self) -> bool {
         self.lifetimes.len() + self.ty_params.len() == 0
     }
index 0164f807f4b5f9f3ba01e6f06d43ab1e2d4b3ecc..7820bb5e964fe983cdd063bd2b04895cd86eac8c 100644 (file)
@@ -38,7 +38,7 @@ enum Junction {
     Disjunction,
 }
 
-impl Junction {
+pub impl Junction {
     fn to_binop(self) -> binop {
         match self {
             Conjunction => and,
index 05d5cee47f2c866b822fb6fa754961c9e74c2d4c..92452cbe8fdc41b49fbdc3ee0c3dca69325a6ccd 100644 (file)
@@ -4,7 +4,7 @@ pub struct Fish {
     x: int
 }
 
-impl Fish {
+pub impl Fish {
     fn swim(&self) {}
 }
 
index e1be3adcd4a02c35f32ea7efc5e6b1585e68c51b..e7a929547255468a24d360daef58468fb000f1d9 100644 (file)
@@ -11,7 +11,7 @@
 
 enum S = ();
 
-impl S {
+pub impl S {
     fn foo() { }
 }
 
index 2845596e780079956767992d27140fd5ce05af09..5e73b286530db901c4a01a26e6835606f0c1f2f2 100644 (file)
@@ -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) {
         {
index 39caba9273293ba24bf7f31fdf08a1e9c24515e8..9825671bc8aea74734dce21fe6efc0d0990fe3d5 100644 (file)
@@ -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];
index 7d68d6d0c3864203c9413961f67af8abdbb15e74..0a2834a95e62edfe85e299427e36372ee923a954 100644 (file)
@@ -14,7 +14,7 @@ struct cat {
   how_hungry : int,
 }
 
-impl cat {
+pub impl cat {
 
   fn speak() { self.meows += 1u; }
 }
index b3ef5f4d481c6d2771b8fd29cb1aa81762cc8a34..068bb7cd7a61d86eeb1d9ef233e3c9888918a036 100644 (file)
@@ -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)
     }
index 4e0cc76bf7543e19dd9392cc512b0335858b865e..2c68429baec926eadd428eca46ed1f1d15cb4c96 100644 (file)
@@ -12,7 +12,7 @@ struct Foo {
     x: int,
 }
 
-impl Foo {
+pub impl Foo {
     fn f(&self) {}
     fn g(&const self) {}
     fn h(&mut self) {}
index e0fca586b6b7bc41f67c0b71ebbaf2b6e1649840..476a790b85ede49d8db7f85e56a1f22e99ed4707 100644 (file)
@@ -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);
index e15edd8cf199c9d54b7f51d883431d2c12e6f05c..61cf346ffa4848b41a71c48385c73e3cea94cf9a 100644 (file)
@@ -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
     }
index 671298040a90b2df88b8b37b8e15ab2c9b8115d4..3169b0299a0bbe8ef4d39cf4fcab0927197684a7 100644 (file)
@@ -19,7 +19,7 @@ struct cat {
   name : ~str,
 }
 
-impl cat {
+pub impl cat {
 
   fn eat() -> bool {
     if self.how_hungry > 0 {
index 30a9fadaeb08b2ea11a49ed6bf6e7aea10e657f4..9a574b984ca4758a9e2e63d56afc4972cbd57c15 100644 (file)
@@ -14,6 +14,6 @@ struct cat {
   tail: int,
 }
 
-impl cat {
+pub impl cat {
   fn meow() { tail += 1; } //~ ERROR: Did you mean: `self.tail`
 }
index 77a840e7e366dd372b9e286fea59df0b8f1b289f..8ec63ddc634c5892eec5c2c7c1a3f5c8751ad9e6 100644 (file)
@@ -14,7 +14,7 @@ pub mod server {
         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.
index 1d4cd69c54ee0a23a6693b1778da31a6934e76ac..e6d16042445e8dbb69320792e14818354e436e9d 100644 (file)
@@ -16,7 +16,7 @@ struct siphash {
         v0: u64,
     }
 
-    impl siphash {
+    pub impl siphash {
         fn reset(&mut self) {
            self.v0 = k0 ^ 0x736f6d6570736575; //~ ERROR attempted dynamic environment-capture
            //~^ ERROR unresolved name: `k0`.
index d7a214dc76bda537c50b2d74bc994b7e9faba4f0..530dadd7e90944bdd539ef0282ef48c97a00e1b4 100644 (file)
@@ -10,7 +10,7 @@
 
 // xfail-test
 enum x = ();
-impl x {
+pub impl x {
     unsafe fn with() { } // This should fail
 }
 
index a09a87d9a6bf28d7a2cf1c6b96a162703e5eb58a..1207ddcb9a042f6083e82b9ec2e11aa27b3c7c7e 100644 (file)
@@ -14,7 +14,7 @@ struct Foo {
     u: ~()
 }
 
-impl Foo {
+pub impl Foo {
     fn get_s(&self) -> &self/str {
         self.s
     }
index c166c400b36de1744622c374f57a3019ed003363..040bd46ab8c8dd7779308bfdebb6906115b78399 100644 (file)
@@ -13,7 +13,7 @@ struct Obj {
     member: uint
 }
 
-impl Obj {
+pub impl Obj {
     static pure fn boom() -> bool {
         return 1+1 == 2
     }
index ea4b70c3c290844efa2016f0941468d47ec84f0c..09a3f3d89c46ce57a4643859c13fd13252a6f9b2 100644 (file)
@@ -15,7 +15,7 @@ pub struct MyStruct {
     pub fn MyStruct () -> MyStruct {
         MyStruct {priv_field: 4}
     }
-    impl MyStruct {
+    pub impl MyStruct {
         priv fn happyfun() {}
     }
 }
index 04ba25fc07d643cc8b14472c252fb2d1525e4bdc..3a63cdee20c83bc2a4c94f6a390a33f90b30cf89 100644 (file)
@@ -15,7 +15,7 @@ struct cat {
   how_hungry : int,
 }
 
-impl cat {
+pub impl cat {
   fn eat() {
     self.how_hungry -= 5;
   }
index c6c89a3ae04a7cb74a1858c8c182c64b9aeb1a44..96657edb5b1addcf66ae4de45c68bd2913b25835 100644 (file)
@@ -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;
index 8e98d4341a8b33553ff82270ecb51d8744589261..b9a9e2f38f5aa2299ba990187a033a011e5982d6 100644 (file)
@@ -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
index 0634205140b5ddc48097096d833903d7c2208f67..dc7c7cec65f3fcc7d5d474fd0c603dfaff2cc25b 100644 (file)
@@ -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() { }
 }
 
index a06bc42d29aba242291f517ab614e113fb38e48d..b0a2bc8ec1275a370f70256ac45e8604fd9a30f1 100644 (file)
@@ -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
index 7ad41b518a13182bcc1ba867bedde159bc065304..3eded9fd4f39c1370627e3c3fcd5d20bf543d3d7 100644 (file)
@@ -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
index 4143c12cf670eec9ccefc650db47631dc076f6fe..2ec0b59e13feebcd6fc2772eccba13498c7a6802 100644 (file)
@@ -12,7 +12,7 @@ struct Foo {
     x: int
 }
 
-impl Foo {
+pub impl Foo {
     static fn new() -> Foo {
         Foo { x: 3 }
     }
index 80f20b13bddafa3c2ebf088d5f5a18fa523e4944..1b4c22e80f3e627610f6ef93dc5fb6583e8afdaf 100644 (file)
@@ -13,7 +13,7 @@
 
 enum Foo = uint;
 
-impl Foo {
+pub impl Foo {
     fn len(&self) -> uint { **self }
 }
 
index 6e6d289e90fbd0482f02465defed7c9d294632be..883cffa792bfbb9c4275ab6b29f11086652633de 100644 (file)
@@ -12,7 +12,7 @@ struct Foo {
     x: int,
 }
 
-impl Foo {
+pub impl Foo {
     fn f(&const self) {}
 }
 
index 748672ef050fb034b879993277c7305dbea5c11a..d8612155f6cd7feb480ca0b5f3380112036a91bb 100644 (file)
@@ -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);
index f35a91c2b914f0dfde7eca6d32f38c8da7458b4d..7c5d5c4d126fc4fc510486c94e03427b48877be6 100644 (file)
@@ -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 }
 }
 
index 157ea586c2c4e48b0e506c7109dcabcc39467517..581361c154c488a11fec152351a0b59d5316dafc 100644 (file)
@@ -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");
index 40f728d40bfe3b3f74755bbc410450f165d1d8a8..f71675c06be0ab681500b0a57a849e6f2ab7db2d 100644 (file)
@@ -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 @@ fn remove(&mut self, k: &int) -> bool {
     }
 }
 
-impl<T> cat<T> {
+pub impl<T> cat<T> {
     pure fn get(&self, k: &int) -> &self/T {
         match self.find(k) {
           Some(v) => { v }
index aa7bb738bf54f31a5f42ce1c52b7df3e82acd29a..aa77dbb62c0a7260ccecf17dae2581d236874008 100644 (file)
@@ -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");
index bdc8f7568a165d8c3c03477793d24df41433d357..896b139110f26352c43e568216609cf88454a147 100644 (file)
@@ -32,7 +32,7 @@ fn meow(&mut self) {
     }
 }
 
-impl cat {
+pub impl cat {
     fn eat(&mut self) -> bool {
         if self.how_hungry > 0 {
             error!("OM NOM NOM");
index 1e41b60a8223ec08f44993ebd430f4abfe19d4bd..f65bcf7be8e69f4c89dc93a46103d59cedd07339 100644 (file)
@@ -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 }
 }
index e81d07a783b99b99636782ae296bfdaf75b8dc6f..654260d8399995a853a449a1cd98104bddc68268 100644 (file)
@@ -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();
     }
index 9c7d9ce7415a433a8dd96d3968fbf1b687d6e52b..728deff8e2db49dbc8661d1f0e5f23bf5940d763 100644 (file)
@@ -18,7 +18,7 @@ struct cat {
     name : ~str,
 }
 
-impl cat {
+pub impl cat {
     fn speak(&mut self) { self.meow(); }
 
     fn eat(&mut self) -> bool {
index cbc69719caa626823b77f67a47df9c329b771ce0..29354c54d8ba096521bb80e01d0ae78738504b3f 100644 (file)
@@ -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 }
 }
index ac80ca9b9e930f54dc5a538bc8a5c31793f2e83a..505537af7a1bc77bbc5287bb170cb34a7a6b5f10 100644 (file)
@@ -14,7 +14,7 @@ struct cat {
     how_hungry : int,
 }
 
-impl cat {
+pub impl cat {
   fn speak(&mut self) {}
 }
 
index 552715dccb445a90bd0f748d10105a0ab16d69da..0d8d7fc37a915ba19100ec6bb0175dfa528c5a2b 100644 (file)
@@ -15,7 +15,7 @@ struct cat {
     name : ~str,
 }
 
-impl cat {
+pub impl cat {
     fn speak(&mut self) { self.meow(); }
 
     fn eat(&mut self) -> bool {
index 268e540c10e33a176e2625b7adf4b6eb430f4c92..35f963d8fb9912d56699a6e44e3c1d32be70bf79 100644 (file)
@@ -2,7 +2,7 @@ struct SpeechMaker {
     speeches: uint
 }
 
-impl SpeechMaker {
+pub impl SpeechMaker {
     pure fn how_many(&self) -> uint { self.speeches }
 }
 
index a2ba4ddb827ba7ed3a664dae73e9f4856b04531a..fd47c262d6a7d225bfb9cae5ce65b64eb00ab18b 100644 (file)
@@ -2,7 +2,7 @@ struct SpeechMaker {
     speeches: uint
 }
 
-impl SpeechMaker {
+pub impl SpeechMaker {
     fn talk(&mut self) {
         self.speeches += 1;
     }
index 19311cb17325a992c8a968472b6fecaf50abba86..57cfdd2f9d4708880696d49d99ce6c05537b63b8 100644 (file)
@@ -11,7 +11,7 @@
 enum E { V, VV(int) }
 const C: E = V;
 
-impl E {
+pub impl E {
     fn method(&self) {
         match *self {
             V => {}
index d40b2f72ae8bac67b76e4772bd6eccff70086369..e019140d1a015103ae0612a6c5c16c45720a4844 100644 (file)
@@ -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; }
     }
index d03893367b4c5cc15b8de135de33ee894d77303a..5df155e4ad3fc4dc4481df4ef4e7ca9a2d1045fd 100644 (file)
@@ -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
     }
index 26e2023e89c50ba75c0e57810fe0f1097b9ac2d1..885eb9837a7109878ead989304819d1419a44d32 100644 (file)
@@ -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 }
index 511529bbc8f7877bef3ee080c65e6f6d7b1bcb05..88e220670ba2c2f859e87924676b6fe8b6da3771 100644 (file)
@@ -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 }
 }
 
index b4141b47b4d6733cb9f15ac82c69dafce23206e3..f60db84eb865f8803d8a5de987933ff65cb458b2 100644 (file)
@@ -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!();
    }
index 12e9157ba2473aed5e75b35f01bd160cb9f474d3..9e45a6b53c2b63f3f303a198f02156a38b7417ab 100644 (file)
@@ -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!(); }
 }
 
index 9869b8d330bf191060ae3d15b932c36fc618b661..73bf97ad7af8dfae85a7bef4c6dd069134850e7a 100644 (file)
@@ -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) {
     }
 }
index 4a085a1eb8a97db65576f43f86368bf4e4d6c821..973b8d851611cde926a65b7969f2ac9123729b85 100644 (file)
@@ -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) {}
 }
 
index 198a8c900d77b44cfd4d13a06ecb90b9a524644d..33023db5323fcf625a400462c9a2273fb9fd567f 100644 (file)
@@ -17,7 +17,7 @@ impl Drop for socket {
     fn finalize(&self) {}
 }
 
-impl socket {
+pub impl socket {
 
     fn set_identity()  {
         do closure {
index 7696ec3721729e541eeda77816f31d67fef29c41..57e5aa39864c06f6a109abb937b977cbe83db84a 100644 (file)
@@ -12,7 +12,7 @@ struct font {
     fontbuf: &self/~[u8],
 }
 
-impl font {
+pub impl font {
     fn buf() -> &self/~[u8] {
         self.fontbuf
     }
index ef65531e5546f51ce986d3cd3915ec5374082122..9ecc46c17ac346d00b7e0d3acb3f20d63d812a26 100644 (file)
@@ -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();
index 0d1b0b9d0029efe4c5d0cc3fa49e026f26637ca1..2f7cb998e1ae6d687697d733d0ae833f71404cd1 100644 (file)
@@ -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,
index fdc50220014f34181cc31f33931d99cd9b0a4cc9..b113e902963b5eefb10765ea969cd53bd3745d40 100644 (file)
@@ -10,7 +10,7 @@
 
 struct Foo { x: int }
 
-impl Foo {
+pub impl Foo {
     fn stuff(&mut self) -> &self/mut Foo {
         return self;
     }
index 8f2b13b6eb028e98b8bc79f9337d27891b6c5a19..1a09a8b860f8454f627d7f9b4c89de2a9663134a 100644 (file)
@@ -23,7 +23,7 @@ struct X {
     err: ErrPrinter
 }
 
-impl X {
+pub impl X {
     fn boom() {
         exit(self.err, "prog", "arg");
     }
index 762b89f5101cd5905da2e2cf43a48e3e1f17996d..56c16d928741d5e61b6113882220bb6d7e03c77a 100644 (file)
@@ -17,7 +17,7 @@ struct Foo {
     y: int,
 }
 
-impl Foo {
+pub impl Foo {
     fn sum() -> int {
         self.x + self.y
     }
index 37ce1bce9e65973858b295af5bbd4bf6fc851137..d84646957283a77411fb1313d175c1cee02d9a93 100644 (file)
@@ -2,7 +2,7 @@ struct S {
     x: ~str
 }
 
-impl S {
+pub impl S {
     fn foo(self) {
         self.bar();
     }
index 149e346bb477b1e4e89850379803cf477d947d0f..2f2930dbab7c7f3e8eff839ce4203b78137de864 100644 (file)
@@ -14,7 +14,7 @@ struct b {
     i: int,
   }
 
-  impl b {
+  pub impl b {
     fn do_stuff() -> int { return 37; }
   }
 
index 5a3ed4c608274c46a60cadf20b055fb48eadd3b5..b56f7fa961e2db117c722b2beeb338cce7404955 100644 (file)
@@ -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 }
     }
index 9cb86ffe83707f8ab14d1b4ee3ac66f11eed6664..0abb758bd7e8eb7cce620e9945f95802232d462e 100644 (file)
@@ -14,7 +14,7 @@ struct cat {
     how_hungry : int,
 }
 
-impl cat {
+pub impl cat {
   fn meow_count(&mut self) -> uint { self.meows }
 }
 
index 432c189ae423c742537d60264217430fa6edc524..1fab77cb5c8672d01ca59b506ded367e1faffc14 100644 (file)
@@ -14,7 +14,7 @@ struct cat {
     how_hungry : int,
 }
 
-impl cat {
+pub impl cat {
     fn play(&mut self) {
         self.meows += 1u;
         self.nap();
index 27afde631b2abe146ac89f2d8f75e521ae02ac50..98e42bd7b4df82052fd9f483693859bedebd9789 100644 (file)
@@ -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));
index 3dc4ca7bd61dc13a7aa891564fca33d4cb479fce..2b00aea2b4cef68f1b1162941b6d99626858cd92 100644 (file)
@@ -18,7 +18,7 @@ fn finalize(&self) {
     }
 }
 
-impl shrinky_pointer {
+pub impl shrinky_pointer {
   fn look_at() -> int { return **(self.i); }
 }