Skip to content

Commit 42fa58e

Browse files
committed
bump MSRV to 1.27.2
closes #154
1 parent 8a5f404 commit 42fa58e

File tree

3 files changed

+3
-14
lines changed

3 files changed

+3
-14
lines changed

.travis.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
language: rust
22
matrix:
33
include:
4-
- rust: 1.24.1
4+
- rust: 1.27.2
55
- rust: stable
66
script:
77
- cargo test

README.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -15,7 +15,7 @@ as well as anything that requires non-const function calls to be computed.
1515

1616
## Minimum supported `rustc`
1717

18-
`1.24.1+`
18+
`1.27.2+`
1919

2020
This version is explicitly tested in CI and may only be bumped in new minor versions. Any changes to the supported minimum version will be called out in the release notes.
2121

src/inline_lazy.rs

Lines changed: 1 addition & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -10,6 +10,7 @@ extern crate std;
1010

1111
use self::std::prelude::v1::*;
1212
use self::std::cell::Cell;
13+
use self::std::hint::unreachable_unchecked;
1314
use self::std::sync::Once;
1415
#[allow(deprecated)]
1516
pub use self::std::sync::ONCE_INIT;
@@ -54,15 +55,3 @@ macro_rules! __lazy_static_create {
5455
static $NAME: $crate::lazy::Lazy<$T> = $crate::lazy::Lazy::INIT;
5556
};
5657
}
57-
58-
/// Polyfill for std::hint::unreachable_unchecked. There currently exists a
59-
/// [crate](https://docs.rs/unreachable) for an equivalent to std::hint::unreachable_unchecked, but
60-
/// lazy_static currently doesn't include any runtime dependencies and we've chosen to include this
61-
/// short polyfill rather than include a new crate in every consumer's build.
62-
///
63-
/// This should be replaced by std's version when lazy_static starts to require at least Rust 1.27.
64-
unsafe fn unreachable_unchecked() -> ! {
65-
enum Void {}
66-
#[allow(deprecated)]
67-
match std::mem::uninitialized::<Void>() {}
68-
}

0 commit comments

Comments
 (0)