File tree Expand file tree Collapse file tree 3 files changed +0
-18
lines changed Expand file tree Collapse file tree 3 files changed +0
-18
lines changed Original file line number Diff line number Diff line change @@ -19,7 +19,6 @@ use crate::{
19
19
#[ derive( Debug , Clone , PartialEq , Eq ) ]
20
20
pub struct FunctionData {
21
21
pub name : Name ,
22
- pub param_names : Vec < Option < Name > > ,
23
22
pub params : Vec < TypeRef > ,
24
23
pub ret_type : TypeRef ,
25
24
pub attrs : Attrs ,
@@ -40,7 +39,6 @@ impl FunctionData {
40
39
41
40
Arc :: new ( FunctionData {
42
41
name : func. name . clone ( ) ,
43
- param_names : func. param_names . to_vec ( ) ,
44
42
params : func. params . to_vec ( ) ,
45
43
ret_type : func. ret_type . clone ( ) ,
46
44
attrs : item_tree. attrs ( ModItem :: from ( loc. id . value ) . into ( ) ) . clone ( ) ,
Original file line number Diff line number Diff line change @@ -507,8 +507,6 @@ pub struct Function {
507
507
pub has_self_param : bool ,
508
508
pub has_body : bool ,
509
509
pub is_unsafe : bool ,
510
- /// List of function parameters names. Does not include `self`.
511
- pub param_names : Box < [ Option < Name > ] > ,
512
510
pub params : Box < [ TypeRef ] > ,
513
511
pub is_varargs : bool ,
514
512
pub ret_type : TypeRef ,
Original file line number Diff line number Diff line change @@ -283,7 +283,6 @@ impl Ctx {
283
283
let name = func. name ( ) ?. as_name ( ) ;
284
284
285
285
let mut params = Vec :: new ( ) ;
286
- let mut param_names = Vec :: new ( ) ;
287
286
let mut has_self_param = false ;
288
287
if let Some ( param_list) = func. param_list ( ) {
289
288
if let Some ( self_param) = param_list. self_param ( ) {
@@ -306,18 +305,6 @@ impl Ctx {
306
305
has_self_param = true ;
307
306
}
308
307
for param in param_list. params ( ) {
309
- let param_name = param
310
- . pat ( )
311
- . map ( |name| {
312
- if let ast:: Pat :: IdentPat ( ident) = name {
313
- Some ( ident. name ( ) ?. as_name ( ) )
314
- } else {
315
- None
316
- }
317
- } )
318
- . flatten ( ) ;
319
- param_names. push ( param_name) ;
320
-
321
308
let type_ref = TypeRef :: from_ast_opt ( & self . body_ctx , param. ty ( ) ) ;
322
309
params. push ( type_ref) ;
323
310
}
@@ -354,7 +341,6 @@ impl Ctx {
354
341
has_body,
355
342
is_unsafe : func. unsafe_token ( ) . is_some ( ) ,
356
343
params : params. into_boxed_slice ( ) ,
357
- param_names : param_names. into_boxed_slice ( ) ,
358
344
is_varargs,
359
345
ret_type,
360
346
ast_id,
You can’t perform that action at this time.
0 commit comments