@@ -154,7 +154,6 @@ use std::slice;
154
154
155
155
use crate :: require_c_abi_if_c_variadic;
156
156
use crate :: util:: common:: indenter;
157
- use crate :: TypeAndSubsts ;
158
157
159
158
use self :: autoderef:: Autoderef ;
160
159
use self :: callee:: DeferredCallResolution ;
@@ -4251,24 +4250,6 @@ impl<'a, 'tcx> FnCtxt<'a, 'tcx> {
4251
4250
}
4252
4251
}
4253
4252
4254
- // Determine the `Self` type, using fresh variables for all variables
4255
- // declared on the impl declaration e.g., `impl<A,B> for Vec<(A,B)>`
4256
- // would return `($0, $1)` where `$0` and `$1` are freshly instantiated type
4257
- // variables.
4258
- pub fn impl_self_ty (
4259
- & self ,
4260
- span : Span , // (potential) receiver for this impl
4261
- did : DefId ,
4262
- ) -> TypeAndSubsts < ' tcx > {
4263
- let ity = self . tcx . type_of ( did) ;
4264
- debug ! ( "impl_self_ty: ity={:?}" , ity) ;
4265
-
4266
- let substs = self . fresh_substs_for_item ( span, did) ;
4267
- let substd_ty = self . instantiate_type_scheme ( span, & substs, & ity) ;
4268
-
4269
- TypeAndSubsts { substs, ty : substd_ty }
4270
- }
4271
-
4272
4253
/// Unifies the output type with the expected type early, for more coercions
4273
4254
/// and forward type information on the input expressions.
4274
4255
fn expected_inputs_for_expected_output (
0 commit comments