Skip to content

Commit

Permalink
Check not(feature = ...) code in cargo.lint Makefile command
Browse files Browse the repository at this point in the history
  • Loading branch information
tyranron committed Nov 21, 2023
1 parent 38c202e commit 25b3dcd
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 0 deletions.
1 change: 1 addition & 0 deletions Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -73,6 +73,7 @@ cargo.fmt:
# make cargo.lint

cargo.lint:
cargo clippy --workspace -- -D warnings
cargo clippy --workspace --all-features -- -D warnings


Expand Down
4 changes: 4 additions & 0 deletions src/event.rs
Original file line number Diff line number Diff line change
Expand Up @@ -53,6 +53,10 @@ pub struct Event<T: ?Sized> {

impl<T> Event<T> {
/// Creates a new [`Event`] out of the given `value`.
#[cfg_attr(
not(feature = "timestamps"),
allow(clippy::missing_const_for_fn)
)]
#[must_use]
pub fn new(value: T) -> Self {
Self {
Expand Down

0 comments on commit 25b3dcd

Please sign in to comment.