@@ -1072,10 +1072,13 @@ fn impl_complex_enum(
1072
1072
quote ! {
1073
1073
impl <' py> #pyo3_path:: conversion:: IntoPyObject <' py> for #cls {
1074
1074
type Target = Self ;
1075
- type Output = #pyo3_path:: Bound <' py, Self :: Target >;
1075
+ type Output = #pyo3_path:: Bound <' py, < Self as #pyo3_path :: conversion :: IntoPyObject < ' py>> :: Target >;
1076
1076
type Error = #pyo3_path:: PyErr ;
1077
1077
1078
- fn into_pyobject( self , py: #pyo3_path:: Python <' py>) -> :: std:: result:: Result <Self :: Output , Self :: Error > {
1078
+ fn into_pyobject( self , py: #pyo3_path:: Python <' py>) -> :: std:: result:: Result <
1079
+ <Self as #pyo3_path:: conversion:: IntoPyObject >:: Output ,
1080
+ <Self as #pyo3_path:: conversion:: IntoPyObject >:: Error ,
1081
+ > {
1079
1082
match self {
1080
1083
#( #match_arms) *
1081
1084
}
@@ -2161,10 +2164,13 @@ impl<'a> PyClassImplsBuilder<'a> {
2161
2164
2162
2165
impl <' py> #pyo3_path:: conversion:: IntoPyObject <' py> for #cls {
2163
2166
type Target = Self ;
2164
- type Output = #pyo3_path:: Bound <' py, Self :: Target >;
2167
+ type Output = #pyo3_path:: Bound <' py, < Self as #pyo3_path :: conversion :: IntoPyObject < ' py>> :: Target >;
2165
2168
type Error = #pyo3_path:: PyErr ;
2166
2169
2167
- fn into_pyobject( self , py: #pyo3_path:: Python <' py>) -> :: std:: result:: Result <Self :: Output , Self :: Error > {
2170
+ fn into_pyobject( self , py: #pyo3_path:: Python <' py>) -> :: std:: result:: Result <
2171
+ <Self as #pyo3_path:: conversion:: IntoPyObject >:: Output ,
2172
+ <Self as #pyo3_path:: conversion:: IntoPyObject >:: Error ,
2173
+ > {
2168
2174
#pyo3_path:: Bound :: new( py, self )
2169
2175
}
2170
2176
}
0 commit comments