@@ -4140,20 +4140,20 @@ impl<'hir> FnDecl<'hir> {
41404140 None
41414141 }
41424142
4143- pub fn implicit_self ( & self ) -> ImplicitSelfKind {
4143+ pub const fn implicit_self ( & self ) -> ImplicitSelfKind {
41444144 self . fn_decl_kind . implicit_self ( )
41454145 }
41464146
4147- pub fn c_variadic ( & self ) -> bool {
4147+ pub const fn c_variadic ( & self ) -> bool {
41484148 self . fn_decl_kind . c_variadic ( )
41494149 }
41504150
4151- pub fn lifetime_elision_allowed ( & self ) -> bool {
4151+ pub const fn lifetime_elision_allowed ( & self ) -> bool {
41524152 self . fn_decl_kind . lifetime_elision_allowed ( )
41534153 }
41544154
41554155 /// Returns `true` if the function has a splatted argument.
4156- pub fn has_splatted_arg ( & self ) -> bool {
4156+ pub const fn has_splatted_arg ( & self ) -> bool {
41574157 self . fn_decl_kind . has_splatted_arg ( )
41584158 }
41594159
@@ -4179,8 +4179,7 @@ impl<'hir> FnDecl<'hir> {
41794179
41804180 /// Returns a dummy FnDecl with the given span, no inputs, no output, and lifetime elision
41814181 /// allowed.
4182- #[ inline]
4183- pub fn dummy ( span : Span ) -> Self {
4182+ pub const fn dummy ( span : Span ) -> Self {
41844183 Self {
41854184 inputs : & [ ] ,
41864185 output : FnRetTy :: DefaultReturn ( span) ,
@@ -4207,7 +4206,7 @@ pub enum ImplicitSelfKind {
42074206
42084207impl ImplicitSelfKind {
42094208 /// Does this represent an implicit self?
4210- pub fn has_implicit_self ( & self ) -> bool {
4209+ pub const fn has_implicit_self ( & self ) -> bool {
42114210 !matches ! ( * self , ImplicitSelfKind :: None )
42124211 }
42134212}
0 commit comments