CI: deny warnings in anvil

This commit is contained in:
Victor Berger 2021-07-25 10:08:40 +02:00 committed by Victor Berger
parent f366dfd12a
commit 3387957065
3 changed files with 20 additions and 11 deletions

View File

@ -94,6 +94,9 @@ jobs:
- default - default
- all - all
env:
RUSTFLAGS: "-D warnings"
runs-on: ubuntu-latest runs-on: ubuntu-latest
steps: steps:

View File

@ -8,25 +8,31 @@ use crate::AnvilState;
use smithay::{ use smithay::{
backend::input::{ backend::input::{
self, Device, DeviceCapability, Event, InputBackend, InputEvent, KeyState, KeyboardKeyEvent, self, Event, InputBackend, InputEvent, KeyState, KeyboardKeyEvent, PointerAxisEvent,
PointerAxisEvent, PointerButtonEvent, ProximityState, TabletToolButtonEvent, TabletToolEvent, PointerButtonEvent,
TabletToolProximityEvent, TabletToolTipEvent, TabletToolTipState,
}, },
reexports::wayland_server::protocol::wl_pointer, reexports::wayland_server::protocol::wl_pointer,
utils::{Logical, Point},
wayland::{ wayland::{
output::Mode,
seat::{keysyms as xkb, AxisFrame, Keysym, ModifiersState}, seat::{keysyms as xkb, AxisFrame, Keysym, ModifiersState},
tablet_manager::{TabletDescriptor, TabletSeatTrait},
SERIAL_COUNTER as SCOUNTER, SERIAL_COUNTER as SCOUNTER,
}, },
}; };
#[cfg(feature = "winit")] #[cfg(feature = "winit")]
use smithay::backend::input::PointerMotionAbsoluteEvent; use smithay::{backend::input::PointerMotionAbsoluteEvent, wayland::output::Mode};
#[cfg(feature = "udev")] #[cfg(feature = "udev")]
use smithay::backend::{input::PointerMotionEvent, session::Session}; use smithay::{
backend::{
input::{
Device, DeviceCapability, PointerMotionEvent, ProximityState, TabletToolButtonEvent,
TabletToolEvent, TabletToolProximityEvent, TabletToolTipEvent, TabletToolTipState,
},
session::Session,
},
utils::{Logical, Point},
wayland::tablet_manager::{TabletDescriptor, TabletSeatTrait},
};
impl<Backend> AnvilState<Backend> { impl<Backend> AnvilState<Backend> {
fn keyboard_key_to_action<B: InputBackend>(&mut self, evt: B::KeyboardKeyEvent) -> KeyAction { fn keyboard_key_to_action<B: InputBackend>(&mut self, evt: B::KeyboardKeyEvent) -> KeyAction {

View File

@ -1,4 +1,4 @@
use slog::{crit, info, o, Drain}; use slog::{crit, o, Drain};
static POSSIBLE_BACKENDS: &[&str] = &[ static POSSIBLE_BACKENDS: &[&str] = &[
#[cfg(feature = "winit")] #[cfg(feature = "winit")]
@ -21,12 +21,12 @@ fn main() {
match arg.as_ref().map(|s| &s[..]) { match arg.as_ref().map(|s| &s[..]) {
#[cfg(feature = "winit")] #[cfg(feature = "winit")]
Some("--winit") => { Some("--winit") => {
info!(log, "Starting anvil with winit backend"); slog::info!(log, "Starting anvil with winit backend");
anvil::winit::run_winit(log); anvil::winit::run_winit(log);
} }
#[cfg(feature = "udev")] #[cfg(feature = "udev")]
Some("--tty-udev") => { Some("--tty-udev") => {
info!(log, "Starting anvil on a tty using udev"); slog::info!(log, "Starting anvil on a tty using udev");
anvil::udev::run_udev(log); anvil::udev::run_udev(log);
} }
Some(other) => { Some(other) => {