@@ -105,7 +105,7 @@ dissimilar = "1.0.7"
105105either = " 1.9.0"
106106expect-test = " 1.4.0"
107107hashbrown = { version = " 0.14" , features = [
108- " inline-more" ,
108+ " inline-more" ,
109109], default-features = false }
110110indexmap = " 2.1.0"
111111itertools = " 0.12.0"
@@ -118,9 +118,9 @@ semver = "1.0.14"
118118serde = { version = " 1.0.192" , features = [" derive" ] }
119119serde_json = " 1.0.108"
120120smallvec = { version = " 1.10.0" , features = [
121- " const_new" ,
122- " union" ,
123- " const_generics" ,
121+ " const_new" ,
122+ " union" ,
123+ " const_generics" ,
124124] }
125125smol_str = " 0.2.1"
126126text-size = " 1.1.1"
@@ -138,8 +138,49 @@ xshell = "0.2.5"
138138# We need to freeze the version of the crate, as the raw-api feature is considered unstable
139139dashmap = { version = " =5.5.3" , features = [" raw-api" ] }
140140
141+ [workspace .lints .rust ]
142+ rust_2018_idioms = " warn"
143+ unused_lifetimes = " warn"
144+ semicolon_in_expressions_from_macros = " warn"
145+
141146[workspace .lints .clippy ]
147+ # TODO: Remove the tidy test once the lint table is stable
148+
149+ # lint groups
150+ complexity = { level = " warn" , priority = -1 }
151+ correctness = { level = " deny" , priority = -1 }
152+ perf = { level = " deny" , priority = -1 }
153+ restriction = { level = " allow" , priority = -1 }
154+ style = { level = " warn" , priority = -1 }
155+ suspicious = { level = " warn" , priority = -1 }
156+
157+ # allow following lints
142158collapsible_if = " allow"
143159needless_pass_by_value = " allow"
144160nonminimal_bool = " allow"
145161redundant_pattern_matching = " allow"
162+ # () makes a fine error in most cases
163+ result_unit_err = " allow"
164+ # We don't expose public APIs that matter like this
165+ len_without_is_empty = " allow"
166+ # We currently prefer explicit control flow return over `...?;` statements whose result is unused
167+ question_mark = " allow"
168+ # We have macros that rely on this currently
169+ enum_variant_names = " allow"
170+ # Builder pattern disagrees
171+ new_ret_no_self = " allow"
172+ non_canonical_clone_impl = " allow"
173+ non_canonical_partial_ord_impl = " allow"
174+ format_collect = " allow"
175+
176+ # Following lints should be tackled at some point
177+ too_many_arguments = " allow"
178+ type_complexity = " allow"
179+
180+ # warn at following lints
181+ dbg_macro = " warn"
182+ todo = " warn"
183+ unimplemented = " warn"
184+ rc_buffer = " warn"
185+ # FIXME enable this, we use this pattern a lot so its annoying work ...
186+ # str_to_string = "warn"
0 commit comments