Skip to content

Commit c6af9ea

Browse files
committed
Add Clippy msrv configuration file
This allows us to automatically ignore lints that are incompatible with our MSRV. Signed-off-by: Joe Richey <[email protected]>
1 parent 1f73c19 commit c6af9ea

File tree

3 files changed

+5
-3
lines changed

3 files changed

+5
-3
lines changed

.clippy.toml

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1 @@
1+
msrv = "1.34"

.github/workflows/tests.yml

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -174,8 +174,11 @@ jobs:
174174
- uses: actions-rs/toolchain@v1
175175
with:
176176
profile: minimal
177-
toolchain: stable
177+
# https://github.com/rust-lang/rust-clippy/pull/6379 added MSRV
178+
# support, so we need to use nightly until this is on stable.
179+
toolchain: nightly
178180
components: rustfmt, clippy
181+
override: true
179182
- name: clippy
180183
run: cargo clippy --all
181184
- name: fmt

src/lib.rs

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -146,8 +146,6 @@
146146
)]
147147
#![no_std]
148148
#![warn(rust_2018_idioms, unused_lifetimes, missing_docs)]
149-
// `matches!` macro was added only in Rust 1.42, which is bigger than our MSRV
150-
#![allow(clippy::match_like_matches_macro)]
151149

152150
#[macro_use]
153151
extern crate cfg_if;

0 commit comments

Comments
 (0)