Commit 7bc39af9 authored by Vladimir Kazakov's avatar Vladimir Kazakov Committed by Thomas Daede

Add Clippy to CI

parent 774b0d1e
language: rust
rust:
- stable
addons:
apt:
packages: binutils-dev libcurl4-openssl-dev zlib1g-dev libdw-dev libiberty-dev
......@@ -33,5 +35,10 @@ jobs:
script: cargo test --verbose --release --features=decode_test -- --ignored
- name: "Bench"
script: cargo bench --verbose
- name: "Clippy (linter): verifying code quality"
script:
rustup component add clippy &&
cargo clippy --version &&
cargo clippy -- -D warnings -A clippy::all --verbose
- name: "Doc"
script: cargo doc --verbose
......@@ -11,10 +11,10 @@
#![allow(non_upper_case_globals)]
#![allow(dead_code)]
#![allow(non_camel_case_types)]
#![cfg_attr(feature = "cargo-clippy", allow(cast_lossless))]
#![cfg_attr(feature = "cargo-clippy", allow(unnecessary_mut_passed))]
#![cfg_attr(feature = "cargo-clippy", allow(needless_range_loop))]
#![cfg_attr(feature = "cargo-clippy", allow(collapsible_if))]
#![allow(clippy::cast_lossless)]
#![allow(clippy::unnecessary_mut_passed)]
#![allow(clippy::needless_range_loop)]
#![allow(clippy::collapsible_if)]
use ec::Writer;
use encoder::{FrameInvariants, ReferenceMode};
......
......@@ -9,9 +9,9 @@
// PATENTS file, you can obtain it at www.aomedia.org/license/patent.
#![allow(non_camel_case_types)]
#![cfg_attr(feature = "cargo-clippy", allow(cast_lossless))]
#![cfg_attr(feature = "cargo-clippy", allow(identity_op))]
#![cfg_attr(feature = "cargo-clippy", allow(needless_range_loop))]
#![allow(clippy::cast_lossless)]
#![allow(clippy::identity_op)]
#![allow(clippy::needless_range_loop)]
use bitstream_io::{BitWriter, BigEndian};
use std;
......
......@@ -8,7 +8,7 @@
// PATENTS file, you can obtain it at www.aomedia.org/license/patent.
#![allow(safe_extern_statics)]
#![cfg_attr(feature = "cargo-clippy", allow(collapsible_if))]
#![allow(clippy::collapsible_if)]
extern crate bitstream_io;
extern crate backtrace;
......
......@@ -7,7 +7,7 @@
// Media Patent License 1.0 was not distributed with this source code in the
// PATENTS file, you can obtain it at www.aomedia.org/license/patent.
#![cfg_attr(feature = "cargo-clippy", allow(cast_lossless))]
#![allow(clippy::cast_lossless)]
use std::iter::FusedIterator;
......
......@@ -8,8 +8,8 @@
// PATENTS file, you can obtain it at www.aomedia.org/license/patent.
#![allow(non_upper_case_globals)]
#![cfg_attr(feature = "cargo-clippy", allow(cast_lossless))]
#![cfg_attr(feature = "cargo-clippy", allow(needless_range_loop))]
#![allow(clippy::cast_lossless)]
#![allow(clippy::needless_range_loop)]
use context::{INTRA_MODES, MAX_TX_SIZE};
use partition::*;
......
......@@ -7,7 +7,7 @@
// Media Patent License 1.0 was not distributed with this source code in the
// PATENTS file, you can obtain it at www.aomedia.org/license/patent.
#![cfg_attr(feature = "cargo-clippy", allow(cast_lossless))]
#![allow(clippy::cast_lossless)]
#![allow(non_upper_case_globals)]
use partition::TxSize;
......
......@@ -9,7 +9,7 @@
// PATENTS file, you can obtain it at www.aomedia.org/license/patent.
#![allow(non_camel_case_types)]
#![cfg_attr(feature = "cargo-clippy", allow(cast_lossless))]
#![allow(clippy::cast_lossless)]
use api::PredictionModesSetting;
use cdef::*;
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment