Skip to content

Commit

Permalink
Automated fixes to follow Rust development
Browse files Browse the repository at this point in the history
Applied fixes:
	*attribute fix (cf rust-lang/rust#2569)
	*crate extra was removed
	*priv attribute removal (cf rust-lang/rust@f2a5c7a)
	*update the channel constructor (cf rust-lang/rust@7858065)
  • Loading branch information
Geal committed Apr 2, 2014
1 parent 6a37763 commit 7087ec0
Show file tree
Hide file tree
Showing 8 changed files with 21 additions and 21 deletions.
4 changes: 2 additions & 2 deletions src/example/main.rs
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
#[crate_id = "redis-example#0.1"];
#[crate_type = "bin"];
#![crate_id = "redis-example#0.1"]
#![crate_type = "bin"]

extern crate redis;

Expand Down
4 changes: 2 additions & 2 deletions src/redis/client.rs
Original file line number Diff line number Diff line change
Expand Up @@ -11,8 +11,8 @@ use connection::Connection;
mod macros;

pub struct Client {
priv addr: SocketAddr,
priv db: i64,
addr: SocketAddr,
db: i64,
}

impl Client {
Expand Down
6 changes: 3 additions & 3 deletions src/redis/connection.rs
Original file line number Diff line number Diff line change
Expand Up @@ -117,9 +117,9 @@ fn value_to_byte_float_tuples(val: Value) -> ~[(~[u8], f32)] {
}

pub struct Connection {
priv addr: SocketAddr,
priv sock: TcpStream,
priv db: i64,
addr: SocketAddr,
sock: TcpStream,
db: i64,
}

impl Connection {
Expand Down
20 changes: 10 additions & 10 deletions src/redis/lib.rs
Original file line number Diff line number Diff line change
@@ -1,16 +1,16 @@
#[crate_id = "redis#0.1"];
#[crate_type = "lib"];
#[license = "BSD"];
#[comment = "Bindings and wrapper functions for redis."];
#![crate_id = "redis#0.1"]
#![crate_type = "lib"]
#![license = "BSD"]
#![comment = "Bindings and wrapper functions for redis."]

#![deny(non_camel_case_types)]
#![feature(macro_rules)]
#![feature(globs)]

#[deny(non_camel_case_types)];
#[feature(macro_rules)];
#[feature(globs)];

extern crate extra;
extern crate time;
extern crate collections;
extern crate serialize;
extern crate collections;
extern crate time;

pub use parser::parse_redis_value;
pub use parser::Parser;
Expand Down
2 changes: 1 addition & 1 deletion src/redis/macros.rs
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
#[macro_escape];
#![macro_escape]

macro_rules! ensure {
($expr:expr, $err_result:expr) => (
Expand Down
2 changes: 1 addition & 1 deletion src/redis/parser.rs
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@ mod macros;


pub struct Parser<T> {
priv iter: T,
iter: T,
}

pub struct ByteIterator<'a> {
Expand Down
2 changes: 1 addition & 1 deletion src/redis/test.rs
Original file line number Diff line number Diff line change
Expand Up @@ -131,7 +131,7 @@ fn test_script() {
fn test_blpop() {
let ctx = TestContext::new();
let client = ctx.client;
let (port, chan) = Chan::new();
let (port, chan) = comm::channel();

spawn(proc() {
let mut con = client.get_connection().unwrap();
Expand Down
2 changes: 1 addition & 1 deletion src/redis/utils.rs
Original file line number Diff line number Diff line change
Expand Up @@ -22,7 +22,7 @@ pub type EVP_MD_CTX = *libc::c_void;
pub type EVP_MD = *libc::c_void;

pub struct Sha1 {
priv ctx: EVP_MD_CTX,
ctx: EVP_MD_CTX,
}

impl Sha1 {
Expand Down

0 comments on commit 7087ec0

Please sign in to comment.