diff --git a/scopegraphs/src/containers/scope.rs b/scopegraphs/src/containers/scope.rs index 36cc94f..b53a4e8 100644 --- a/scopegraphs/src/containers/scope.rs +++ b/scopegraphs/src/containers/scope.rs @@ -36,7 +36,7 @@ pub trait ScopeContainer<'sg, 'rslv, LABEL: Debug + 'sg, DATA: 'sg>: Debug { /// # trait DBound<'sg>: Hash + Eq + 'sg {} /// /// fn test<'sg, 'rslv, LABEL: LBound<'sg>, DATA: DBound<'sg>, DWFO>( -/// cont: impl ScopeContainerWf<'sg, 'rslv, LABEL, DATA, DWFO> +/// cont: impl ScopeContainerWf<'sg, 'rslv, LABEL, DATA, DWFO, DWFO> /// ) { } /// /// # fn scope_vec<'sg, 'rslv, LABEL: LBound<'sg>, DATA: DBound<'sg>>() { @@ -64,9 +64,9 @@ pub trait ScopeContainer<'sg, 'rslv, LABEL: Debug + 'sg, DATA: 'sg>: Debug { /// # use std::hash::Hash; /// /// -/// fn test<'sg, 'rslv, LABEL: Clone + Hash + Eq + Debug + 'sg, DATA: Hash + Eq + 'sg, DWFO>(cont: impl ScopeContainerWf<'sg, 'rslv, LABEL, DATA, DWFO>) { -/// -/// } +/// fn test<'sg, 'rslv, LABEL: Clone + Hash + Eq + Debug + 'sg, DATA: Hash + Eq + 'sg, DWFO>( +/// cont: impl ScopeContainerWf<'sg, 'rslv, LABEL, DATA, DWFO, DWFO> +/// ) { } /// ``` /// /// ```no_run @@ -78,9 +78,9 @@ pub trait ScopeContainer<'sg, 'rslv, LABEL: Debug + 'sg, DATA: 'sg>: Debug { /// test::<'_, '_, (), (), bool>(Result::<_, ()>::Ok(Vec::::new())); /// test::<'_, '_, (), (), Result>(Result::<_, ()>::Ok(Vec::::new())); /// -/// fn test<'sg, 'rslv, LABEL: Clone + Hash + Eq + Debug + 'sg, DATA: Hash + Eq + 'sg, DWFO>(cont: impl ScopeContainerWf<'sg, 'rslv, LABEL, DATA, DWFO>) { -/// -/// } +/// fn test<'sg, 'rslv, LABEL: Clone + Hash + Eq + Debug + 'sg, DATA: Hash + Eq + 'sg, DWFO>( +/// cont: impl ScopeContainerWf<'sg, 'rslv, LABEL, DATA, DWFO, DWFO> +/// ) { } /// ``` /// pub trait ScopeContainerWf<'sg, 'rslv, LABEL, DATA, DWFO, DEQO>: diff --git a/scopegraphs/src/resolve/lookup.rs b/scopegraphs/src/resolve/lookup.rs index 6bbac3e..559972a 100644 --- a/scopegraphs/src/resolve/lookup.rs +++ b/scopegraphs/src/resolve/lookup.rs @@ -227,12 +227,19 @@ where let mut base_env = base_env.clone(); let sub_env = local_self.resolve_edge(path_wellformedness.clone(), edge, path); sub_env.flat_map(move |sub_env| { - let filtered_env: EnvC<'sg, 'rslv, CMPL, LABEL, DATA, DWF::Output, DEq::Output> = - Filterable::filter(&base_env, sub_env, local_self.data_equiv); - filtered_env.flat_map(move |filtered_env| { - base_env.merge(filtered_env); - base_env.into() - }) + let filtered_env: EnvC< + 'sg, + 'rslv, + CMPL, + LABEL, + DATA, + DWF::Output, + DEq::Output, + > = Filterable::filter(&base_env, sub_env, local_self.data_equiv); + filtered_env.flat_map(move |filtered_env| { + base_env.merge(filtered_env); + base_env.into() + }) }) } }))