mirror of
https://github.com/vulkano-rs/vulkano.git
synced 2024-11-21 22:34:43 +00:00
Run clippy in CI (#2443)
* Run clippy in CI * Fix clippy warnings in build output * Update PR template
This commit is contained in:
parent
e243c2699d
commit
e7f37adfa9
8
.github/PULL_REQUEST_TEMPLATE.md
vendored
8
.github/PULL_REQUEST_TEMPLATE.md
vendored
@ -2,16 +2,18 @@
|
|||||||
|
|
||||||
2. [ ] Make sure that the changes are covered by unit-tests.
|
2. [ ] Make sure that the changes are covered by unit-tests.
|
||||||
|
|
||||||
3. [ ] Run `cargo +nightly fmt` on the changes.
|
3. [ ] Run `cargo clippy` on the changes.
|
||||||
|
|
||||||
4. [ ] Please put changelog entries **in the description of this Pull Request**
|
4. [ ] Run `cargo +nightly fmt` on the changes.
|
||||||
|
|
||||||
|
5. [ ] Please put changelog entries **in the description of this Pull Request**
|
||||||
if knowledge of this change could be valuable to users. No need to put the
|
if knowledge of this change could be valuable to users. No need to put the
|
||||||
entries to the changelog directly, they will be transferred to the changelog
|
entries to the changelog directly, they will be transferred to the changelog
|
||||||
file by maintainers right after the Pull Request merge.
|
file by maintainers right after the Pull Request merge.
|
||||||
|
|
||||||
Please remove any items from the template below that are not applicable.
|
Please remove any items from the template below that are not applicable.
|
||||||
|
|
||||||
5. [ ] Describe in common words what is the purpose of this change, related
|
6. [ ] Describe in common words what is the purpose of this change, related
|
||||||
Github Issues, and highlight important implementation aspects.
|
Github Issues, and highlight important implementation aspects.
|
||||||
|
|
||||||
Changelog:
|
Changelog:
|
||||||
|
10
.github/workflows/rust.yml
vendored
10
.github/workflows/rust.yml
vendored
@ -51,11 +51,19 @@ jobs:
|
|||||||
run: |
|
run: |
|
||||||
cd examples
|
cd examples
|
||||||
cargo build --verbose
|
cargo build --verbose
|
||||||
|
clippy:
|
||||||
|
runs-on: ubuntu-latest
|
||||||
|
steps:
|
||||||
|
- uses: actions/checkout@v3
|
||||||
|
- name: Run clippy check
|
||||||
|
run: |
|
||||||
|
rustup component add clippy
|
||||||
|
cargo clippy -- -Dwarnings
|
||||||
fmt:
|
fmt:
|
||||||
runs-on: ubuntu-latest
|
runs-on: ubuntu-latest
|
||||||
steps:
|
steps:
|
||||||
- uses: actions/checkout@v3
|
- uses: actions/checkout@v3
|
||||||
- name: Check formatting
|
- name: Run fmt check
|
||||||
run: |
|
run: |
|
||||||
rustup toolchain install nightly --component rustfmt
|
rustup toolchain install nightly --component rustfmt
|
||||||
cargo +nightly fmt --check
|
cargo +nightly fmt --check
|
||||||
|
@ -254,11 +254,16 @@ fn device_extensions_output(members: &[ExtensionsMember]) -> TokenStream {
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
);
|
)
|
||||||
|
.collect::<Vec<_>>();
|
||||||
|
|
||||||
quote! {
|
if requires_all_of_items.is_empty() {
|
||||||
if self.#name {
|
quote! {}
|
||||||
#(#requires_all_of_items)*
|
} else {
|
||||||
|
quote! {
|
||||||
|
if self.#name {
|
||||||
|
#(#requires_all_of_items)*
|
||||||
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
|
Loading…
Reference in New Issue
Block a user