mirror of
https://github.com/salsa-rs/salsa.git
synced 2025-01-22 21:05:11 +00:00
allow various clippy lint groups
This commit is contained in:
parent
3257fa95a7
commit
82b672df3b
4 changed files with 6 additions and 3 deletions
|
@ -95,6 +95,7 @@ fn struct_item_out(
|
||||||
fn inherent_impl(args: &Args, struct_ty: &syn::Type, data_ty: &syn::Type) -> syn::ItemImpl {
|
fn inherent_impl(args: &Args, struct_ty: &syn::Type, data_ty: &syn::Type) -> syn::ItemImpl {
|
||||||
let jar_ty = args.jar_ty();
|
let jar_ty = args.jar_ty();
|
||||||
parse_quote_spanned! { struct_ty.span() =>
|
parse_quote_spanned! { struct_ty.span() =>
|
||||||
|
#[allow(dead_code, clippy::pedantic, clippy::complexity, clippy::style)]
|
||||||
impl #struct_ty {
|
impl #struct_ty {
|
||||||
pub fn push<DB: ?Sized>(db: &DB, data: #data_ty)
|
pub fn push<DB: ?Sized>(db: &DB, data: #data_ty)
|
||||||
where
|
where
|
||||||
|
@ -116,6 +117,7 @@ fn ingredients_for_impl(
|
||||||
let jar_ty = args.jar_ty();
|
let jar_ty = args.jar_ty();
|
||||||
let debug_name = crate::literal(struct_name);
|
let debug_name = crate::literal(struct_name);
|
||||||
parse_quote_spanned! { struct_name.span() =>
|
parse_quote_spanned! { struct_name.span() =>
|
||||||
|
#[allow(dead_code, clippy::pedantic, clippy::complexity, clippy::style)]
|
||||||
impl salsa::storage::IngredientsFor for #struct_name {
|
impl salsa::storage::IngredientsFor for #struct_name {
|
||||||
type Ingredients = salsa::accumulator::AccumulatorIngredient<#data_ty>;
|
type Ingredients = salsa::accumulator::AccumulatorIngredient<#data_ty>;
|
||||||
type Jar = #jar_ty;
|
type Jar = #jar_ty;
|
||||||
|
@ -143,6 +145,7 @@ fn ingredients_for_impl(
|
||||||
fn accumulator_impl(args: &Args, struct_ty: &syn::Type, data_ty: &syn::Type) -> syn::ItemImpl {
|
fn accumulator_impl(args: &Args, struct_ty: &syn::Type, data_ty: &syn::Type) -> syn::ItemImpl {
|
||||||
let jar_ty = args.jar_ty();
|
let jar_ty = args.jar_ty();
|
||||||
parse_quote_spanned! { struct_ty.span() =>
|
parse_quote_spanned! { struct_ty.span() =>
|
||||||
|
#[allow(dead_code, clippy::pedantic, clippy::complexity, clippy::style)]
|
||||||
impl salsa::accumulator::Accumulator for #struct_ty {
|
impl salsa::accumulator::Accumulator for #struct_ty {
|
||||||
type Data = #data_ty;
|
type Data = #data_ty;
|
||||||
type Jar = #jar_ty;
|
type Jar = #jar_ty;
|
||||||
|
|
|
@ -192,7 +192,7 @@ impl InputStruct {
|
||||||
}
|
}
|
||||||
} else {
|
} else {
|
||||||
parse_quote! {
|
parse_quote! {
|
||||||
#[allow(dead_code)]
|
#[allow(dead_code, clippy::pedantic, clippy::complexity, clippy::style)]
|
||||||
impl #ident {
|
impl #ident {
|
||||||
#constructor
|
#constructor
|
||||||
|
|
||||||
|
|
|
@ -131,7 +131,7 @@ impl InternedStruct {
|
||||||
};
|
};
|
||||||
|
|
||||||
parse_quote! {
|
parse_quote! {
|
||||||
#[allow(dead_code)]
|
#[allow(dead_code, clippy::pedantic, clippy::complexity, clippy::style)]
|
||||||
impl #id_ident {
|
impl #id_ident {
|
||||||
#(#field_getters)*
|
#(#field_getters)*
|
||||||
|
|
||||||
|
|
|
@ -194,7 +194,7 @@ impl TrackedStruct {
|
||||||
let constructor_name = self.constructor_name();
|
let constructor_name = self.constructor_name();
|
||||||
|
|
||||||
parse_quote! {
|
parse_quote! {
|
||||||
#[allow(clippy::too_many_arguments)]
|
#[allow(dead_code, clippy::pedantic, clippy::complexity, clippy::style)]
|
||||||
impl #ident {
|
impl #ident {
|
||||||
pub fn #constructor_name(__db: &#db_dyn_ty, #(#field_names: #field_tys,)*) -> Self
|
pub fn #constructor_name(__db: &#db_dyn_ty, #(#field_names: #field_tys,)*) -> Self
|
||||||
{
|
{
|
||||||
|
|
Loading…
Reference in a new issue