File tree Expand file tree Collapse file tree 1 file changed +11
-2
lines changed Expand file tree Collapse file tree 1 file changed +11
-2
lines changed Original file line number Diff line number Diff line change @@ -673,8 +673,13 @@ impl Function {
673
673
Some ( SelfParam { func : self . id } )
674
674
}
675
675
676
- pub fn params ( self , db : & dyn HirDatabase ) -> Vec < TypeRef > {
677
- db. function_data ( self . id ) . params . clone ( )
676
+ pub fn params ( self , db : & dyn HirDatabase ) -> Vec < Param > {
677
+ db. function_data ( self . id )
678
+ . params
679
+ . iter ( )
680
+ . skip ( if self . self_param ( db) . is_some ( ) { 1 } else { 0 } )
681
+ . map ( |_| Param { _ty : ( ) } )
682
+ . collect ( )
678
683
}
679
684
680
685
pub fn is_unsafe ( self , db : & dyn HirDatabase ) -> bool {
@@ -707,6 +712,10 @@ pub struct SelfParam {
707
712
func : FunctionId ,
708
713
}
709
714
715
+ pub struct Param {
716
+ _ty : ( ) ,
717
+ }
718
+
710
719
impl SelfParam {
711
720
pub fn access ( self , db : & dyn HirDatabase ) -> Access {
712
721
let func_data = db. function_data ( self . func ) ;
You can’t perform that action at this time.
0 commit comments