diff --git a/crates/biome_analyze/src/options.rs b/crates/biome_analyze/src/options.rs index f659eda99015..52c13a52978e 100644 --- a/crates/biome_analyze/src/options.rs +++ b/crates/biome_analyze/src/options.rs @@ -94,8 +94,7 @@ impl AnalyzerOptions { pub fn rule_options(&self) -> Option where - R: Rule + 'static, - R::Options: Clone, + R: Rule + 'static, { self.configuration .rules @@ -105,8 +104,7 @@ impl AnalyzerOptions { pub fn rule_fix_kind(&self) -> Option where - R: Rule + 'static, - R::Options: Clone, + R: Rule + 'static, { self.configuration .rules diff --git a/crates/biome_analyze/src/registry.rs b/crates/biome_analyze/src/registry.rs index e6ecd189934c..56f5f1fa0355 100644 --- a/crates/biome_analyze/src/registry.rs +++ b/crates/biome_analyze/src/registry.rs @@ -50,9 +50,7 @@ pub trait RegistryVisitor { /// Record the rule `R` to this visitor fn record_rule(&mut self) where - R: Rule + 'static, - R::Query: Queryable, - ::Output: Clone; + R: Rule> + 'static; } /// Stores metadata information for all the rules in the registry, sorted @@ -85,9 +83,7 @@ impl MetadataRegistry { impl RegistryVisitor for MetadataRegistry { fn record_rule(&mut self) where - R: Rule + 'static, - R::Query: Queryable, - ::Output: Clone, + R: Rule> + 'static, { self.insert_rule(::NAME, R::METADATA.name); } @@ -165,10 +161,7 @@ impl RegistryVisitor for RuleRegistryBuilder /// Add the rule `R` to the list of rules stores in this registry instance fn record_rule(&mut self) where - R: Rule + 'static, - ::Options: Default, - R::Query: Queryable, - ::Output: Clone, + R: Rule> + 'static, { if !self.filter.match_rule::() { return; @@ -384,10 +377,7 @@ type RuleExecutor = fn(&mut MatchQueryParams, &mut RuleState) -> Result impl RegistryRule { fn new(state_index: usize) -> Self where - R: Rule + 'static, - ::Options: Default, - R::Query: Queryable + 'static, - ::Output: Clone, + R: Rule> + 'static, { /// Generic implementation of RuleExecutor for any rule type R fn run( @@ -395,10 +385,7 @@ impl RegistryRule { state: &mut RuleState>, ) -> Result<(), Error> where - R: Rule + 'static, - R::Query: 'static, - ::Output: Clone, - ::Options: Default, + R: Rule> + 'static, { if let Some(node) = params.query.downcast_ref::>>() { if state.suppressions.inner.contains(node) { diff --git a/crates/biome_analyze/src/signals.rs b/crates/biome_analyze/src/signals.rs index d377069134ae..d69e97b77f8b 100644 --- a/crates/biome_analyze/src/signals.rs +++ b/crates/biome_analyze/src/signals.rs @@ -342,8 +342,7 @@ where impl<'bag, R> AnalyzerSignal> for RuleSignal<'bag, R> where - R: Rule + 'static, - ::Options: Default, + R: Rule + 'static, { fn diagnostic(&self) -> Option { let globals = self.options.globals(); diff --git a/crates/biome_deserialize/src/impls.rs b/crates/biome_deserialize/src/impls.rs index c397d5e90948..98d6b95e9f96 100644 --- a/crates/biome_deserialize/src/impls.rs +++ b/crates/biome_deserialize/src/impls.rs @@ -14,7 +14,6 @@ use std::{ num::{NonZeroU16, NonZeroU32, NonZeroU64, NonZeroU8, NonZeroUsize}, ops::Deref, path::PathBuf, - u8, }; /// Type that allows deserializing a string without heap-allocation. diff --git a/crates/biome_formatter/src/lib.rs b/crates/biome_formatter/src/lib.rs index b4414e3c8cb8..63a8296046c5 100644 --- a/crates/biome_formatter/src/lib.rs +++ b/crates/biome_formatter/src/lib.rs @@ -76,7 +76,6 @@ pub use source_map::{TransformSourceMap, TransformSourceMapBuilder}; use std::marker::PhantomData; use std::num::ParseIntError; use std::str::FromStr; -use std::u8; use token::string::Quote; #[derive(Debug, Eq, PartialEq, Clone, Copy, Hash)] diff --git a/crates/biome_js_analyze/src/lint/nursery/use_sorted_classes/sort_config.rs b/crates/biome_js_analyze/src/lint/nursery/use_sorted_classes/sort_config.rs index e9ceefabf9d7..d5edc96f4eb4 100644 --- a/crates/biome_js_analyze/src/lint/nursery/use_sorted_classes/sort_config.rs +++ b/crates/biome_js_analyze/src/lint/nursery/use_sorted_classes/sort_config.rs @@ -22,6 +22,7 @@ pub type VariantsConfig = Vec; /// The sort config, containing the utility config and the variant config. pub struct SortConfig { pub utilities: &'static [UtilityLayer], + #[allow(dead_code)] pub variants: VariantsConfig, pub layer_index_map: HashMap<&'static str, usize>, } diff --git a/crates/biome_text_size/src/size.rs b/crates/biome_text_size/src/size.rs index f7f27d0a2be2..41948e0b77c0 100644 --- a/crates/biome_text_size/src/size.rs +++ b/crates/biome_text_size/src/size.rs @@ -5,7 +5,6 @@ use { fmt, iter, num::TryFromIntError, ops::{Add, AddAssign, Sub, SubAssign}, - u32, }, }; diff --git a/rust-toolchain.toml b/rust-toolchain.toml index 480124d7150e..07e2d0e86063 100644 --- a/rust-toolchain.toml +++ b/rust-toolchain.toml @@ -2,4 +2,4 @@ # The default profile includes rustc, rust-std, cargo, rust-docs, rustfmt and clippy. # https://rust-lang.github.io/rustup/concepts/profiles.html profile = "default" -channel = "1.78.0" +channel = "1.79.0" diff --git a/xtask/codegen/src/js_kinds_src.rs b/xtask/codegen/src/js_kinds_src.rs index 1b39ec4a3515..ee98d0b2567c 100644 --- a/xtask/codegen/src/js_kinds_src.rs +++ b/xtask/codegen/src/js_kinds_src.rs @@ -574,6 +574,7 @@ pub struct AstListSeparatorConfiguration { #[derive(Debug)] pub struct AstNodeSrc { + #[allow(dead_code)] pub documentation: Vec, pub name: String, // pub traits: Vec, @@ -607,6 +608,7 @@ pub enum Field { #[derive(Debug, Clone)] pub struct AstEnumSrc { + #[allow(dead_code)] pub documentation: Vec, pub name: String, // pub traits: Vec,