diff options
| author | Noam Koren <noam575@gmail.com> | 2021-02-27 19:13:10 +0200 |
|---|---|---|
| committer | Noam Koren <noam575@gmail.com> | 2021-03-01 22:59:24 +0200 |
| commit | 854fffde5d491e5a6faddcda99b2a2f36801c71f (patch) | |
| tree | a26c005288713386a5c6a8e871e26fbe0c85753a /compiler/rustc_trait_selection/src | |
| parent | 5233edcf1c7ee70ac25e4ec1115c3546f53d8a2d (diff) | |
| download | rust-854fffde5d491e5a6faddcda99b2a2f36801c71f.tar.gz rust-854fffde5d491e5a6faddcda99b2a2f36801c71f.zip | |
Get TyCtxt from self instead of passing as argument in AutoTraitFinder
methods
Diffstat (limited to 'compiler/rustc_trait_selection/src')
| -rw-r--r-- | compiler/rustc_trait_selection/src/traits/auto_trait.rs | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/compiler/rustc_trait_selection/src/traits/auto_trait.rs b/compiler/rustc_trait_selection/src/traits/auto_trait.rs index 97cc258d425..6510c9464e1 100644 --- a/compiler/rustc_trait_selection/src/traits/auto_trait.rs +++ b/compiler/rustc_trait_selection/src/traits/auto_trait.rs @@ -77,7 +77,7 @@ impl<'tcx> AutoTraitFinder<'tcx> { ty: Ty<'tcx>, orig_env: ty::ParamEnv<'tcx>, trait_did: DefId, - mut auto_trait_callback: impl FnMut(&InferCtxt<'_, 'tcx>, AutoTraitInfo<'tcx>) -> A, + mut auto_trait_callback: impl FnMut(AutoTraitInfo<'tcx>) -> A, ) -> AutoTraitResult<A> { let tcx = self.tcx; @@ -211,7 +211,7 @@ impl<'tcx> AutoTraitFinder<'tcx> { let info = AutoTraitInfo { full_user_env, region_data, vid_to_region }; - AutoTraitResult::PositiveImpl(auto_trait_callback(&infcx, info)) + AutoTraitResult::PositiveImpl(auto_trait_callback(info)) }) } } |
