Skip to content

Commit

Permalink
fix(rustup): switch to unstable features
Browse files Browse the repository at this point in the history
  • Loading branch information
seanmonstar committed Jan 31, 2015
1 parent 4ad4c49 commit 3af8b68
Show file tree
Hide file tree
Showing 15 changed files with 20 additions and 19 deletions.
2 changes: 1 addition & 1 deletion benches/client.rs
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
#![allow(unstable)]
#![feature(core, io, test)]
extern crate hyper;

extern crate test;
Expand Down
2 changes: 1 addition & 1 deletion benches/client_mock_tcp.rs
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
#![allow(unstable)]
#![feature(core, collections, io, test)]
extern crate hyper;

extern crate test;
Expand Down
4 changes: 2 additions & 2 deletions benches/server.rs
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
#![allow(unstable)]
#![feature(io, test)]
extern crate hyper;
extern crate test;

Expand Down Expand Up @@ -26,7 +26,7 @@ fn bench_hyper(b: &mut Bencher) {
let server = hyper::Server::http(Ipv4Addr(127, 0, 0, 1), 0);
let mut listener = server.listen(hyper_handle).unwrap();

let url = hyper::Url::parse(format!("http://{}", listener.socket).as_slice()).unwrap();
let url = hyper::Url::parse(&*format!("http://{}", listener.socket)).unwrap();
b.iter(|| request(url.clone()));
listener.close().unwrap();
}
Expand Down
2 changes: 1 addition & 1 deletion examples/client.rs
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
#![allow(unstable)]
#![feature(os, io)]
extern crate hyper;

use std::os;
Expand Down
2 changes: 1 addition & 1 deletion examples/hello.rs
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
#![allow(unstable)]
#![feature(io)]
extern crate hyper;

use std::old_io::net::ip::Ipv4Addr;
Expand Down
4 changes: 2 additions & 2 deletions examples/server.rs
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
#![allow(unstable)]
#![feature(core, io)]
extern crate hyper;
#[macro_use] extern crate log;

Expand All @@ -21,7 +21,7 @@ macro_rules! try_return(

fn echo(mut req: Request, mut res: Response) {
match req.uri {
AbsolutePath(ref path) => match (&req.method, path.as_slice()) {
AbsolutePath(ref path) => match (&req.method, &path[]) {
(&Get, "/") | (&Get, "/echo") => {
let out = b"Try POST /echo";

Expand Down
2 changes: 1 addition & 1 deletion src/header/common/access_control/allow_headers.rs
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@ use header;
/// > during the actual request.
///
/// Spec: www.w3.org/TR/cors/#access-control-allow-headers-response-header
#[derive(Clone, PartialEq, Show)]
#[derive(Clone, PartialEq, Debug)]
pub struct AccessControlAllowHeaders(pub Vec<String>);

impl header::Header for AccessControlAllowHeaders {
Expand Down
2 changes: 1 addition & 1 deletion src/header/common/access_control/allow_methods.rs
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@ use method;
/// > actual request.
///
/// Spec: www.w3.org/TR/cors/#access-control-allow-methods-response-header
#[derive(Clone, PartialEq, Show)]
#[derive(Clone, PartialEq, Debug)]
pub struct AccessControlAllowMethods(pub Vec<method::Method>);

impl header::Header for AccessControlAllowMethods {
Expand Down
2 changes: 1 addition & 1 deletion src/header/common/access_control/allow_origin.rs
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,7 @@ use header;
/// > "*", or "null" in the response.
///
/// Spec: www.w3.org/TR/cors/#access-control-allow-origin-response-header
#[derive(Clone, PartialEq, Show)]
#[derive(Clone, PartialEq, Debug)]
pub enum AccessControlAllowOrigin {
/// Allow all origins
AllowStar,
Expand Down
2 changes: 1 addition & 1 deletion src/header/common/access_control/max_age.rs
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@ use header;
/// > preflight request can be cached in a preflight result cache.
///
/// Spec: www.w3.org/TR/cors/#access-control-max-age-response-header
#[derive(Clone, Copy, PartialEq, Show)]
#[derive(Clone, Copy, PartialEq, Debug)]
pub struct AccessControlMaxAge(pub u32);

impl header::Header for AccessControlMaxAge {
Expand Down
2 changes: 1 addition & 1 deletion src/header/common/access_control/request_headers.rs
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@ use header;
/// > be used in the actual request as part of the preflight request.
///
/// Spec: www.w3.org/TR/cors/#access-control-request-headers-request-header
#[derive(Clone, PartialEq, Show)]
#[derive(Clone, PartialEq, Debug)]
pub struct AccessControlRequestHeaders(pub Vec<String>);

impl header::Header for AccessControlRequestHeaders {
Expand Down
2 changes: 1 addition & 1 deletion src/header/common/access_control/request_method.rs
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@ use method::Method;
/// > used in the actual request as part of the preflight request.
///
/// Spec: www.w3.org/TR/cors/#access-control-request-method-request-header
#[derive(Clone, PartialEq, Show)]
#[derive(Clone, PartialEq, Debug)]
pub struct AccessControlRequestMethod(pub Method);

impl header::Header for AccessControlRequestMethod {
Expand Down
4 changes: 2 additions & 2 deletions src/header/mod.rs
Original file line number Diff line number Diff line change
Expand Up @@ -484,7 +484,7 @@ impl fmt::Display for Box<HeaderFormat + Send + Sync> {
}
}

/// A wrapper around any Header with a Show impl that calls fmt_header.
/// A wrapper around any Header with a Display impl that calls fmt_header.
///
/// This can be used like so: `format!("{}", HeaderFormatter(&header))` to
/// get the representation of a Header which will be written to an
Expand Down Expand Up @@ -555,7 +555,7 @@ mod tests {
assert_eq!(accept, Some(Accept(vec![application_vendor, text_plain])));
}

#[derive(Clone, Show)]
#[derive(Clone, Debug)]
struct CrazyLength(Option<bool>, usize);

impl Header for CrazyLength {
Expand Down
2 changes: 1 addition & 1 deletion src/http.rs
Original file line number Diff line number Diff line change
Expand Up @@ -586,7 +586,7 @@ pub fn read_request_line<R: Reader>(stream: &mut R) -> HttpResult<RequestLine> {
pub type StatusLine = (HttpVersion, RawStatus);

/// The raw status code and reason-phrase.
#[derive(PartialEq, Show)]
#[derive(PartialEq, Debug)]
pub struct RawStatus(pub u16, pub CowString<'static>);

impl Clone for RawStatus {
Expand Down
5 changes: 3 additions & 2 deletions src/lib.rs
Original file line number Diff line number Diff line change
@@ -1,7 +1,8 @@
#![feature(slicing_syntax, box_syntax)]
#![feature(core, collections, hash, io, os, std_misc,
slicing_syntax, box_syntax)]
#![deny(missing_docs)]
#![allow(unstable)]
#![cfg_attr(test, deny(warnings))]
#![cfg_attr(test, feature(test))]

//! # Hyper
//! Hyper is a fast, modern HTTP implementation written in and for Rust. It
Expand Down

0 comments on commit 3af8b68

Please sign in to comment.