diff options
-rw-r--r-- | .travis.yml | 20 | ||||
-rw-r--r-- | Cargo.toml | 3 | ||||
-rw-r--r-- | ci/script.sh | 4 | ||||
-rw-r--r-- | src/lib.rs | 7 |
4 files changed, 26 insertions, 8 deletions
diff --git a/.travis.yml b/.travis.yml index 1aead9b..1497c7a 100644 --- a/.travis.yml +++ b/.travis.yml @@ -22,6 +22,26 @@ matrix: rust: stable if: (branch = staging OR branch = trying) OR (type = pull_request AND branch = master) + # MSRV + - env: TARGET=thumbv6m-none-eabi + rust: 1.31.0 + if: (branch = staging OR branch = trying) OR (type = pull_request AND branch = master) + + # MSRV + - env: TARGET=thumbv7m-none-eabi + rust: 1.31.0 + if: (branch = staging OR branch = trying) OR (type = pull_request AND branch = master) + + # MSRV + - env: TARGET=thumbv7em-none-eabi + rust: 1.31.0 + if: (branch = staging OR branch = trying) OR (type = pull_request AND branch = master) + + # MSRV + - env: TARGET=thumbv7em-none-eabihf + rust: 1.31.0 + if: (branch = staging OR branch = trying) OR (type = pull_request AND branch = master) + - env: TARGET=thumbv6m-none-eabi rust: nightly if: (branch = staging OR branch = trying) OR (type = pull_request AND branch = master) @@ -16,10 +16,9 @@ links = "cortex-m" # prevent multiple versions of this crate to be linked toget [dependencies] aligned = "0.3.1" -bare-metal = "0.2.0" +bare-metal = { version = "0.2.0", features = ["const-fn"] } volatile-register = "0.2.0" [features] cm7-r0p1 = [] -const-fn = ["bare-metal/const-fn"] inline-asm = [] diff --git a/ci/script.sh b/ci/script.sh index 20a8ea2..8046774 100644 --- a/ci/script.sh +++ b/ci/script.sh @@ -8,7 +8,7 @@ main() { cargo check --target $TARGET if [ $TRAVIS_RUST_VERSION = nightly ]; then - cargo check --target $TARGET --features 'const-fn inline-asm' + cargo check --target $TARGET --features 'inline-asm' fi case $TARGET in @@ -16,7 +16,7 @@ main() { cargo check --target $TARGET --features cm7-r0p1 if [ $TRAVIS_RUST_VERSION = nightly ]; then - cargo check --target $TARGET --features 'cm7-r0p1 const-fn inline-asm' + cargo check --target $TARGET --features 'cm7-r0p1 inline-asm' fi ;; @@ -24,11 +24,10 @@ //! //! The disadvantage is that `inline-asm` requires a nightly toolchain. //! -//! ## `const-fn` +//! # Minimum Supported Rust Version (MSRV) //! -//! Enabling this feature turns the `Mutex.new` constructor into a `const fn`. -//! -//! This feature requires a nightly toolchain. +//! This crate is guaranteed to compile on stable Rust 1.31 and up. It *might* +//! compile with older versions but that may change in any new patch release. #![cfg_attr(feature = "inline-asm", feature(asm))] #![deny(missing_docs)] |