Skip to content

Commit

Permalink
Remove use of the 'const_fn' feature.
Browse files Browse the repository at this point in the history
  • Loading branch information
jebrosen authored and SergioBenitez committed Sep 4, 2018
1 parent 42361c3 commit 1da506e
Show file tree
Hide file tree
Showing 4 changed files with 3 additions and 5 deletions.
1 change: 0 additions & 1 deletion core/http/src/lib.rs
Original file line number Diff line number Diff line change
@@ -1,6 +1,5 @@
#![feature(specialization)]
#![feature(proc_macro_non_items)]
#![feature(const_fn)]
#![feature(try_from)]
#![feature(crate_visibility_modifier)]
#![recursion_limit="256"]
Expand Down
4 changes: 2 additions & 2 deletions core/http/src/status.rs
Original file line number Diff line number Diff line change
Expand Up @@ -101,7 +101,7 @@ macro_rules! ctrs {
#[doc=$reason]
#[doc="</i>."]
#[allow(non_upper_case_globals)]
pub const $name: Status = Status::new($code, $reason);
pub const $name: Status = Status { code: $code, reason: $reason };
)+

/// Returns a Status given a standard status code `code`. If `code` is
Expand Down Expand Up @@ -155,7 +155,7 @@ impl Status {
/// assert_eq!(custom.to_string(), "299 Somewhat Successful".to_string());
/// ```
#[inline(always)]
pub const fn new(code: u16, reason: &'static str) -> Status {
pub fn new(code: u16, reason: &'static str) -> Status {
Status { code, reason }
}

Expand Down
1 change: 0 additions & 1 deletion core/lib/src/lib.rs
Original file line number Diff line number Diff line change
@@ -1,5 +1,4 @@
#![feature(specialization)]
#![feature(const_fn)]
#![feature(plugin, decl_macro)]
#![feature(try_trait)]
#![feature(fnbox)]
Expand Down
2 changes: 1 addition & 1 deletion examples/todo/src/main.rs
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
#![feature(plugin, decl_macro, custom_derive, const_fn)]
#![feature(plugin, decl_macro, custom_derive)]
#![plugin(rocket_codegen)]

#[macro_use] extern crate rocket;
Expand Down

0 comments on commit 1da506e

Please sign in to comment.