Chore: ignore push-blocking features that would make older rust toolchains error

This commit is contained in:
Denis Benato
2025-11-11 22:21:32 +01:00
parent 7207d3287a
commit 4c6db9f0a9
5 changed files with 9 additions and 3 deletions

View File

@@ -181,6 +181,7 @@ pub struct TwoColourSpeed {
}
#[derive(Debug, Clone, Default, Options)]
#[allow(dead_code)]
pub struct MultiZone {
#[options(help = "print help message")]
help: bool,
@@ -195,6 +196,7 @@ pub struct MultiZone {
}
#[derive(Debug, Clone, Default, Options)]
#[allow(dead_code)]
pub struct MultiColourSpeed {
#[options(help = "print help message")]
help: bool,

View File

@@ -1184,11 +1184,12 @@ fn print_firmware_attr(attr: &AsusArmouryProxyBlocking) -> Result<(), Box<dyn st
Ok(())
}
#[allow(clippy::manual_is_multiple_of, clippy::nonminimal_bool)]
fn handle_armoury_command(cmd: &ArmouryCommand) -> Result<(), Box<dyn std::error::Error>> {
{
if cmd.free.is_empty() || !cmd.free.len().is_multiple_of(2) || cmd.help {
if cmd.free.is_empty() || (cmd.free.len() % 2 != 0) || cmd.help {
const USAGE: &str = "Usage: asusctl platform panel_overdrive 1 nv_dynamic_boost 5";
if !(cmd.free.len() % 2 == 0) {
if cmd.free.len() % 2 != 0 {
println!(
"Incorrect number of args, each attribute label must be paired with a setting:"
);

View File

@@ -102,6 +102,7 @@ pub struct DeviceManager {
}
impl DeviceManager {
#[allow(clippy::type_complexity)]
async fn get_or_create_hid_handle(
handles: &Arc<Mutex<HashMap<String, Arc<Mutex<HidRaw>>>>>,
endpoint: &Device,

View File

@@ -51,6 +51,7 @@ pub struct CtrlPlatform {
}
impl CtrlPlatform {
#[allow(clippy::too_many_arguments)]
pub fn new(
platform: RogPlatform,
power: AsusPower,

View File

@@ -157,8 +157,9 @@ fn main() -> Result<(), Box<dyn Error>> {
for (x_count, b) in dev.buffer[start..=end].iter().enumerate() {
canvas.set_draw_color(Color::RGB(*b, *b, *b));
#[allow(clippy::manual_is_multiple_of)]
let x: i32 = w + x_count as i32 * w
- if !((y_count + y_offset as usize) % 2 == 0) {
- if (y_count + y_offset as usize) % 2 != 0 {
0
} else {
w / 2