Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
3 changes: 2 additions & 1 deletion Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -52,7 +52,8 @@ default-members = [

[workspace.lints.clippy]
ref_as_ptr = "warn"
# NOTE: disallowed-types is configured in other file: clippy.toml
# NOTE: clippy configuration values (disallowed-types and
# large-error-threshold) are in other file: clippy.toml

[workspace.package]
edition = "2021"
Expand Down
6 changes: 5 additions & 1 deletion clippy.toml
Original file line number Diff line number Diff line change
@@ -1,6 +1,10 @@
# NOTE: Other global Clippy config is in top-level Cargo.toml.
# NOTE: Other global Clippy config (severity overrides) is in top-level Cargo.toml.

disallowed-types = [
{ path = "std::collections::HashMap", reason = "use hashbrown::HashMap instead" },
{ path = "std::collections::HashSet", reason = "use hashbrown::HashSet instead" },
]

# The default large-error-threshold is 128. We have a bunch of complex error
# types that are slightly larger than that.
large-error-threshold = 192
3 changes: 1 addition & 2 deletions naga/src/lib.rs
Original file line number Diff line number Diff line change
Expand Up @@ -75,8 +75,7 @@ void main() {
clippy::derive_partial_eq_without_eq,
clippy::needless_borrowed_reference,
clippy::single_match,
clippy::enum_variant_names,
clippy::result_large_err
clippy::enum_variant_names
)]
#![warn(
trivial_casts,
Expand Down
5 changes: 0 additions & 5 deletions naga/tests/naga/validation.rs
Original file line number Diff line number Diff line change
Expand Up @@ -2,11 +2,6 @@
//!
//! There are also some validation tests in [`wgsl_errors`](super::wgsl_errors).

#![allow(
// We need to investigate these.
clippy::result_large_err
)]

use naga::{
ir::{self, Expression, Function, Module, Scalar},
valid::{self, Capabilities, ModuleInfo, ValidationFlags},
Expand Down
4 changes: 0 additions & 4 deletions naga/tests/naga/wgsl_errors.rs
Original file line number Diff line number Diff line change
Expand Up @@ -6,10 +6,6 @@
//! for the validator tests to be in the `validation` test suite.

#![cfg(feature = "wgsl-in")]
#![allow(
// We need to investigate these.
clippy::result_large_err
)]

use naga::{
compact::KeepUnused,
Expand Down
2 changes: 0 additions & 2 deletions wgpu-core/src/lib.rs
Original file line number Diff line number Diff line change
Expand Up @@ -37,8 +37,6 @@
clippy::pattern_type_mismatch,
// `wgpu-core` isn't entirely user-facing, so it's useful to document internal items.
rustdoc::private_intra_doc_links,
// We should investigate these.
clippy::result_large_err
)]
#![warn(
clippy::alloc_instead_of_core,
Expand Down
Loading