From 3757b012953141d9e931cc5d1dbc280cbfed3b31 Mon Sep 17 00:00:00 2001
From: Paul Schulze
Date: Fri, 17 Nov 2023 11:25:28 +0100
Subject: [PATCH] [clippy] since Rust 1.74 linter options can be specified in
Cargo.toml
---
Cargo.toml | 9 +++++++++
src/main.rs | 5 -----
2 files changed, 9 insertions(+), 5 deletions(-)
diff --git a/Cargo.toml b/Cargo.toml
index bdaa5b2..ef96cd3 100644
--- a/Cargo.toml
+++ b/Cargo.toml
@@ -9,6 +9,15 @@ version = "0.4"
default-features = false
features = ["std", "clock"]
+[lints.rust]
+unsafe_code = "forbid"
+
+[lints.clippy]
+pedantic = "warn"
+todo = "warn"
+unwrap_used = "warn"
+inline_always = "allow"
+
[profile.release]
lto = true
debug = false
diff --git a/src/main.rs b/src/main.rs
index 324056a..6e60102 100644
--- a/src/main.rs
+++ b/src/main.rs
@@ -1,8 +1,3 @@
-#![warn(clippy::pedantic)]
-#![warn(clippy::todo)]
-#![warn(clippy::unwrap_used)]
-#![allow(clippy::inline_always)]
-
use std::{
env::args,
fs::File,