Unnamed repository; edit this file 'description' to name the repository.
Diffstat (limited to 'crates/hir-def/src/item_tree/pretty.rs')
-rw-r--r--crates/hir-def/src/item_tree/pretty.rs4
1 files changed, 2 insertions, 2 deletions
diff --git a/crates/hir-def/src/item_tree/pretty.rs b/crates/hir-def/src/item_tree/pretty.rs
index 59031824e1..ad260df80f 100644
--- a/crates/hir-def/src/item_tree/pretty.rs
+++ b/crates/hir-def/src/item_tree/pretty.rs
@@ -570,13 +570,13 @@ impl Printer<'_> {
}
fn print_where_clause(&mut self, params: &GenericParams) -> bool {
- if params.where_predicates.is_empty() {
+ if params.where_predicates().next().is_none() {
return false;
}
w!(self, "\nwhere");
self.indented(|this| {
- for (i, pred) in params.where_predicates.iter().enumerate() {
+ for (i, pred) in params.where_predicates().enumerate() {
if i != 0 {
wln!(this, ",");
}