From ae8a8020857080ea527cc1d0e57a592d6e587a64 Mon Sep 17 00:00:00 2001 From: Lukas Wirth Date: Sun, 13 Dec 2020 11:34:44 +0100 Subject: Ignore lifetime params in substitutions --- crates/hir_def/src/item_tree.rs | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) (limited to 'crates/hir_def') diff --git a/crates/hir_def/src/item_tree.rs b/crates/hir_def/src/item_tree.rs index c6ada271e..b08167281 100644 --- a/crates/hir_def/src/item_tree.rs +++ b/crates/hir_def/src/item_tree.rs @@ -246,7 +246,10 @@ struct GenericParamsStorage { impl GenericParamsStorage { fn alloc(&mut self, params: GenericParams) -> GenericParamsId { - if params.types.is_empty() && params.where_predicates.is_empty() { + if params.types.is_empty() + && params.lifetimes.is_empty() + && params.where_predicates.is_empty() + { return GenericParamsId::EMPTY; } -- cgit v1.2.3