File tree 1 file changed +4
-10
lines changed
1 file changed +4
-10
lines changed Original file line number Diff line number Diff line change @@ -3907,25 +3907,19 @@ impl CodeGenerator for Function {
3907
3907
Linkage :: External => { }
3908
3908
}
3909
3909
3910
- #[ allow( clippy:: needless_late_init) ]
3911
- let is_dynamic_function;
3912
3910
// Pure virtual methods have no actual symbol, so we can't generate
3913
3911
// something meaningful for them.
3914
- match self . kind ( ) {
3912
+ let is_dynamic_function = match self . kind ( ) {
3915
3913
FunctionKind :: Method ( ref method_kind)
3916
3914
if method_kind. is_pure_virtual ( ) =>
3917
3915
{
3918
3916
return None ;
3919
3917
}
3920
3918
FunctionKind :: Function => {
3921
- // If we're generating for dynamic loading, some attributes can not be emitted.
3922
- is_dynamic_function =
3923
- ctx. options ( ) . dynamic_library_name . is_some ( )
3919
+ ctx. options ( ) . dynamic_library_name . is_some ( )
3924
3920
}
3925
- _ => {
3926
- is_dynamic_function = false ;
3927
- }
3928
- }
3921
+ _ => false ,
3922
+ } ;
3929
3923
3930
3924
// Similar to static member variables in a class template, we can't
3931
3925
// generate bindings to template functions, because the set of
You can’t perform that action at this time.
0 commit comments