Skip to content

Commit

Permalink
Make fields in std::comm private
Browse files Browse the repository at this point in the history
  • Loading branch information
chitra authored and chitra committed Oct 18, 2013
1 parent fa03c94 commit bdcd29c
Showing 1 changed file with 6 additions and 6 deletions.
12 changes: 6 additions & 6 deletions src/libstd/comm.rs
Original file line number Diff line number Diff line change
Expand Up @@ -50,16 +50,16 @@ pub trait Peekable<T> {
fn peek(&self) -> bool;
}

pub struct PortOne<T> { x: rtcomm::PortOne<T> }
pub struct ChanOne<T> { x: rtcomm::ChanOne<T> }
pub struct PortOne<T> { priv x: rtcomm::PortOne<T> }
pub struct ChanOne<T> { priv x: rtcomm::ChanOne<T> }

pub fn oneshot<T: Send>() -> (PortOne<T>, ChanOne<T>) {
let (p, c) = rtcomm::oneshot();
(PortOne { x: p }, ChanOne { x: c })
}

pub struct Port<T> { x: rtcomm::Port<T> }
pub struct Chan<T> { x: rtcomm::Chan<T> }
pub struct Port<T> { priv x: rtcomm::Port<T> }
pub struct Chan<T> { priv x: rtcomm::Chan<T> }

pub fn stream<T: Send>() -> (Port<T>, Chan<T>) {
let (p, c) = rtcomm::stream();
Expand Down Expand Up @@ -153,7 +153,7 @@ impl<T: Send> Peekable<T> for Port<T> {
}


pub struct SharedChan<T> { x: rtcomm::SharedChan<T> }
pub struct SharedChan<T> { priv x: rtcomm::SharedChan<T> }

impl<T: Send> SharedChan<T> {
pub fn new(c: Chan<T>) -> SharedChan<T> {
Expand Down Expand Up @@ -195,7 +195,7 @@ impl<T> Clone for SharedChan<T> {
}
}

pub struct SharedPort<T> { x: rtcomm::SharedPort<T> }
pub struct SharedPort<T> { priv x: rtcomm::SharedPort<T> }

impl<T: Send> SharedPort<T> {
pub fn new(p: Port<T>) -> SharedPort<T> {
Expand Down

5 comments on commit bdcd29c

@bors
Copy link
Contributor

@bors bors commented on bdcd29c Oct 18, 2013

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

saw approval from bstrie
at reedlepee123@bdcd29c

@bors
Copy link
Contributor

@bors bors commented on bdcd29c Oct 18, 2013

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

merging reedlepee123/rust/my_new_branch = bdcd29c into auto

@bors
Copy link
Contributor

@bors bors commented on bdcd29c Oct 18, 2013

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

reedlepee123/rust/my_new_branch = bdcd29c merged ok, testing candidate = 6b07d88

@bors
Copy link
Contributor

@bors bors commented on bdcd29c Oct 18, 2013

@bors
Copy link
Contributor

@bors bors commented on bdcd29c Oct 18, 2013

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

fast-forwarding master to auto = 6b07d88

Please sign in to comment.