@@ -7,7 +7,7 @@ use quote::{ToTokens, format_ident, quote};
7
7
use std:: borrow:: Cow ;
8
8
use syn:: parse:: { Parse , ParseStream } ;
9
9
use syn:: punctuated:: Punctuated ;
10
- use syn:: { PatIdent , Type , parse_quote} ;
10
+ use syn:: { LitStr , PatIdent , Type , parse_quote} ;
11
11
12
12
#[ derive( Debug , Clone ) ]
13
13
pub struct PerPixelAdjust { }
@@ -293,6 +293,7 @@ impl PerPixelAdjustCodegen<'_> {
293
293
let mut parsed_node_fn = ParsedNodeFn {
294
294
vis : self . parsed . vis . clone ( ) ,
295
295
attributes : NodeFnAttributes {
296
+ display_name : self . parsed . attributes . display_name . as_ref ( ) . map ( |name| LitStr :: new ( & format ! ( "{} GPU" , name. value( ) ) , name. span ( ) ) ) ,
296
297
shader_node : Some ( ShaderNodeType :: ShaderNode ) ,
297
298
..self . parsed . attributes . clone ( )
298
299
} ,
@@ -310,7 +311,7 @@ impl PerPixelAdjustCodegen<'_> {
310
311
is_async : true ,
311
312
fields,
312
313
body,
313
- description : "" . to_string ( ) ,
314
+ description : self . parsed . description . clone ( ) ,
314
315
} ;
315
316
parsed_node_fn. replace_impl_trait_in_input ( ) ;
316
317
let gpu_node_impl = crate :: codegen:: generate_node_code ( self . crate_ident , & parsed_node_fn) ?;
0 commit comments