Skip to content

Commit

Permalink
silense too many arguments error
Browse files Browse the repository at this point in the history
  • Loading branch information
imor committed Jul 7, 2024
1 parent ee75ed0 commit 00b2825
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 1 deletion.
2 changes: 1 addition & 1 deletion node-graph/gstd/src/raster.rs
Original file line number Diff line number Diff line change
Expand Up @@ -590,8 +590,8 @@ pub struct NoisePatternNode<
cellular_jitter: CellularJitter,
}

#[allow(clippy::too_many_arguments)]
#[node_macro::node_fn(NoisePatternNode)]
#[allow(clippy::too_many_arguments)]
fn noise_pattern(
_no_primary_input: (),
dimensions: UVec2,
Expand Down
3 changes: 3 additions & 0 deletions node-graph/node-macro/src/lib.rs
Original file line number Diff line number Diff line change
Expand Up @@ -141,11 +141,14 @@ fn node_new_impl(attr: TokenStream, item: TokenStream) -> TokenStream {
args.push(Type::Verbatim(quote::quote!(#ident)));
}

let function_attributes = &function.attrs;

let struct_generics_iter = struct_generics.iter();
quote::quote! {
#[automatically_derived]
impl <#(#args),*> #node_name<#(#args),*>
{
#(#function_attributes)*
pub const fn new(#(#parameter_idents: #struct_generics_iter),*) -> Self{
Self {
#(#parameter_idents,)*
Expand Down

0 comments on commit 00b2825

Please sign in to comment.