From f74ca88384cbce7e318a7a0142a9ac3eda6b8641 Mon Sep 17 00:00:00 2001 From: Nilstrieb <48135649+Nilstrieb@users.noreply.github.com> Date: Sat, 21 Jan 2023 20:12:40 +0100 Subject: [PATCH] Use a type-alias-impl-trait in `ObligationForest` --- compiler/rustc_data_structures/src/obligation_forest/mod.rs | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/compiler/rustc_data_structures/src/obligation_forest/mod.rs b/compiler/rustc_data_structures/src/obligation_forest/mod.rs index 10e673cd929..dda422c6dd0 100644 --- a/compiler/rustc_data_structures/src/obligation_forest/mod.rs +++ b/compiler/rustc_data_structures/src/obligation_forest/mod.rs @@ -139,8 +139,7 @@ pub enum ProcessResult { #[derive(Clone, Copy, PartialEq, Eq, Hash, Debug)] struct ObligationTreeId(usize); -type ObligationTreeIdGenerator = - std::iter::Map, fn(usize) -> ObligationTreeId>; +type ObligationTreeIdGenerator = impl Iterator; pub struct ObligationForest { /// The list of obligations. In between calls to [Self::process_obligations],