Skip to content

Commit

Permalink
Clippy fixes (#868)
Browse files Browse the repository at this point in the history
* Clippy-check improvement warnings->errors

* Naming clarification

* Clippy fix

* Even more naming conventions

* Revert "Even more naming conventions"

This reverts commit 394dcd9.

* Clippy fix
  • Loading branch information
greg-szabo authored May 11, 2021
1 parent 0a586d2 commit d910417
Show file tree
Hide file tree
Showing 3 changed files with 6 additions and 4 deletions.
6 changes: 4 additions & 2 deletions .github/workflows/rust.yml
Original file line number Diff line number Diff line change
Expand Up @@ -30,7 +30,8 @@ jobs:
command: fmt
args: --all -- --check

clippy_check:
# This job creates the "clippy-results" GitHub Action that lists the clippy results in a nice format.
clippy-json-output:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v2
Expand All @@ -41,8 +42,9 @@ jobs:
override: true
- uses: actions-rs/clippy-check@v1
with:
name: clippy-results
token: ${{ secrets.GITHUB_TOKEN }}
args: --all-features --all-targets
args: --all-features --all-targets -- -Dwarnings -Drust-2018-idioms

docs:
runs-on: ubuntu-latest
Expand Down
2 changes: 1 addition & 1 deletion light-client-js/src/lib.rs
Original file line number Diff line number Diff line change
Expand Up @@ -24,7 +24,7 @@ use wasm_bindgen::JsValue;
// allocator.
#[cfg(feature = "wee_alloc")]
#[global_allocator]
static ALLOC: wee_alloc::WeeAlloc = wee_alloc::WeeAlloc::INIT;
static ALLOC: wee_alloc::WeeAlloc<'_> = wee_alloc::WeeAlloc::INIT;

/// Check whether a given untrusted block can be trusted.
#[wasm_bindgen]
Expand Down
2 changes: 1 addition & 1 deletion proto/src/serializers/part_set_header_total.rs
Original file line number Diff line number Diff line change
Expand Up @@ -30,7 +30,7 @@ where
impl<'de> Visitor<'de> for PartSetHeaderTotalStringOrU32 {
type Value = u32;

fn expecting(&self, formatter: &mut Formatter) -> std::fmt::Result {
fn expecting(&self, formatter: &mut Formatter<'_>) -> std::fmt::Result {
formatter.write_str("an u32 integer or string between 0 and 2^32")
}

Expand Down

0 comments on commit d910417

Please sign in to comment.