File tree Expand file tree Collapse file tree 1 file changed +12
-3
lines changed
crates/red_knot_python_semantic/src/types Expand file tree Collapse file tree 1 file changed +12
-3
lines changed Original file line number Diff line number Diff line change @@ -839,7 +839,10 @@ impl<'db> TypeInferenceBuilder<'db> {
839
839
. as_deref ( )
840
840
. expect ( "function type params scope without type params" ) ;
841
841
842
- self . infer_optional_annotation_expression ( function. returns . as_deref ( ) ) ;
842
+ self . infer_optional_annotation_expression (
843
+ function. returns . as_deref ( ) ,
844
+ DeferredExpressionState :: None ,
845
+ ) ;
843
846
self . infer_type_parameters ( type_params) ;
844
847
self . infer_parameters ( & function. parameters ) ;
845
848
}
@@ -988,7 +991,10 @@ impl<'db> TypeInferenceBuilder<'db> {
988
991
default : _,
989
992
} = parameter_with_default;
990
993
991
- self . infer_optional_annotation_expression ( parameter. annotation . as_deref ( ) ) ;
994
+ self . infer_optional_annotation_expression (
995
+ parameter. annotation . as_deref ( ) ,
996
+ DeferredExpressionState :: None ,
997
+ ) ;
992
998
}
993
999
994
1000
fn infer_parameter ( & mut self , parameter : & ast:: Parameter ) {
@@ -998,7 +1004,10 @@ impl<'db> TypeInferenceBuilder<'db> {
998
1004
annotation,
999
1005
} = parameter;
1000
1006
1001
- self . infer_optional_annotation_expression ( annotation. as_deref ( ) ) ;
1007
+ self . infer_optional_annotation_expression (
1008
+ annotation. as_deref ( ) ,
1009
+ DeferredExpressionState :: None ,
1010
+ ) ;
1002
1011
}
1003
1012
1004
1013
fn infer_parameter_with_default_definition (
You can’t perform that action at this time.
0 commit comments