From b6c870ea2585fd49c4d6bc4f2175366139269c98 Mon Sep 17 00:00:00 2001 From: Jan-Erik Rediger Date: Tue, 16 Feb 2016 09:18:54 +0100 Subject: [PATCH 1/2] refactor: Remove dependency on regex_macro MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit It was not used in stable at all, because it only works in nightly. Now that regex! is almost always slower¹ there's no reason to keep it in. ¹: https://github.com/rust-lang-nursery/regex/pull/164 --- Cargo.toml | 9 --------- src/lib.rs | 5 ----- src/macros.rs | 3 --- 3 files changed, 17 deletions(-) diff --git a/Cargo.toml b/Cargo.toml index 7dcd6ff..d081ca5 100644 --- a/Cargo.toml +++ b/Cargo.toml @@ -14,17 +14,8 @@ regex = "0.1.41" toml = "0.1.23" time = "0.1.33" -[dependencies.regex_macros] -version = "*" -optional = true - [features] default = [] # For debugging output debug = [] - -# for building with nightly and unstable features -# until regex_macros compiles with nightly again, this should be commented out -# unstable = ["regex_macros"] -unstable = [] diff --git a/src/lib.rs b/src/lib.rs index 178bfa2..e9d090b 100644 --- a/src/lib.rs +++ b/src/lib.rs @@ -1,8 +1,3 @@ -// Until regex_macros compiles on nightly, we comment this out -// -// #![cfg_attr(feature = "unstable", feature(plugin))] -// #![cfg_attr(feature = "unstable", plugin(regex_macros))] - // DOCS extern crate regex; diff --git a/src/macros.rs b/src/macros.rs index f6a907c..c753442 100644 --- a/src/macros.rs +++ b/src/macros.rs @@ -13,9 +13,6 @@ macro_rules! werr( }) ); -// regex cheat thanks to https://github.com/BurntSushi -// Until regex_macros compiles with nightly again, this directive should be commented out -// #[cfg(not(unstable))] macro_rules! regex( ($s:expr) => (::regex::Regex::new($s).unwrap()); ); From 88788ea5513d3554b42424b7fd5203f98e4532cc Mon Sep 17 00:00:00 2001 From: Jan-Erik Rediger Date: Tue, 1 Mar 2016 17:49:42 +0100 Subject: [PATCH 2/2] chore: Add back unstable feature This does not enable anything, but we keep it around nonetheless. --- Cargo.toml | 1 + 1 file changed, 1 insertion(+) diff --git a/Cargo.toml b/Cargo.toml index d081ca5..8653d34 100644 --- a/Cargo.toml +++ b/Cargo.toml @@ -19,3 +19,4 @@ default = [] # For debugging output debug = [] +unstable = []