diff options
Diffstat (limited to 'src/features.rs')
-rw-r--r-- | src/features.rs | 18 |
1 files changed, 13 insertions, 5 deletions
diff --git a/src/features.rs b/src/features.rs index 99b789e..a786f07 100644 --- a/src/features.rs +++ b/src/features.rs @@ -87,8 +87,9 @@ macro_rules! rust_target_base { $x_macro!( /// Rust stable 1.0 => Stable_1_0 => 1.0; - /// Rust stable 1.1 - => Stable_1_1 => 1.1; + /// Rust stable 1.17 + /// * Static lifetime elision ([RFC 1623](https://github.com/rust-lang/rfcs/blob/master/text/1623-static.md)) + => Stable_1_17 => 1.17; /// Rust stable 1.19 /// * Untagged unions ([RFC 1444](https://github.com/rust-lang/rfcs/blob/master/text/1444-union.md)) => Stable_1_19 => 1.19; @@ -191,6 +192,9 @@ macro_rules! rust_feature_def { // documentation for the relevant variant in the rust_target_base macro // definition. rust_feature_def!( + Stable_1_17 { + => static_lifetime_elision; + } Stable_1_19 { => untagged_union; } @@ -249,7 +253,8 @@ mod test { fn target_features() { let f_1_0 = RustFeatures::from(RustTarget::Stable_1_0); assert!( - !f_1_0.core_ffi_c_void && + !f_1_0.static_lifetime_elision && + !f_1_0.core_ffi_c_void && !f_1_0.untagged_union && !f_1_0.associated_const && !f_1_0.builtin_clone_impls && @@ -258,7 +263,8 @@ mod test { ); let f_1_21 = RustFeatures::from(RustTarget::Stable_1_21); assert!( - !f_1_21.core_ffi_c_void && + f_1_21.static_lifetime_elision && + !f_1_21.core_ffi_c_void && f_1_21.untagged_union && f_1_21.associated_const && f_1_21.builtin_clone_impls && @@ -267,7 +273,8 @@ mod test { ); let f_nightly = RustFeatures::from(RustTarget::Nightly); assert!( - f_nightly.core_ffi_c_void && + f_nightly.static_lifetime_elision && + f_nightly.core_ffi_c_void && f_nightly.untagged_union && f_nightly.associated_const && f_nightly.builtin_clone_impls && @@ -286,6 +293,7 @@ mod test { #[test] fn str_to_target() { test_target("1.0", RustTarget::Stable_1_0); + test_target("1.17", RustTarget::Stable_1_17); test_target("1.19", RustTarget::Stable_1_19); test_target("1.21", RustTarget::Stable_1_21); test_target("1.25", RustTarget::Stable_1_25); |