Normalize all types when finishing inference

The new solver does not eagerly normalize, but things after inference expect types to be normalized. rustc does the same.

Also, I'm afraid other things in r-a don't expect results of the solver to be unnormalized. We'll need to handle that.
diff --git a/crates/hir-ty/src/infer/unify.rs b/crates/hir-ty/src/infer/unify.rs
index a709aeb..bb4782b 100644
--- a/crates/hir-ty/src/infer/unify.rs
+++ b/crates/hir-ty/src/infer/unify.rs
@@ -621,6 +621,9 @@
     where
         T: HasInterner<Interner = Interner> + TypeFoldable<Interner>,
     {
+        let t = self.resolve_with_fallback(t, &|_, _, d, _| d);
+        let t = self.normalize_associated_types_in(t);
+        // Resolve again, because maybe normalization inserted infer vars.
         self.resolve_with_fallback(t, &|_, _, d, _| d)
     }
 
diff --git a/crates/hir-ty/src/tests/regression/new_solver.rs b/crates/hir-ty/src/tests/regression/new_solver.rs
index 059f4ad..20190fb 100644
--- a/crates/hir-ty/src/tests/regression/new_solver.rs
+++ b/crates/hir-ty/src/tests/regression/new_solver.rs
@@ -24,3 +24,29 @@
         "#]],
     );
 }
+
+#[test]
+fn normalization() {
+    check_infer(
+        r#"
+//- minicore: iterator, iterators
+fn main() {
+    _ = [0i32].into_iter().filter_map(|_n| Some(1i32));
+}
+    "#,
+        expect![[r#"
+            10..69 '{     ...2)); }': ()
+            16..17 '_': FilterMap<IntoIter<i32, 1>, impl FnMut(i32) -> Option<i32>>
+            16..66 '_ = [0...1i32))': ()
+            20..26 '[0i32]': [i32; 1]
+            20..38 '[0i32]...iter()': IntoIter<i32, 1>
+            20..66 '[0i32]...1i32))': FilterMap<IntoIter<i32, 1>, impl FnMut(i32) -> Option<i32>>
+            21..25 '0i32': i32
+            50..65 '|_n| Some(1i32)': impl FnMut(i32) -> Option<i32>
+            51..53 '_n': i32
+            55..59 'Some': fn Some<i32>(i32) -> Option<i32>
+            55..65 'Some(1i32)': Option<i32>
+            60..64 '1i32': i32
+        "#]],
+    );
+}