add record pat missing field diagnostic

This commit is contained in:
Josh Mcguigan 2020-04-08 20:23:51 -07:00
parent 176f7f6117
commit e63315b8f1
7 changed files with 159 additions and 57 deletions

View file

@ -255,7 +255,7 @@ impl SourceAnalyzer {
_ => return None,
};
let (variant, missing_fields) =
let (variant, missing_fields, _exhaustive) =
record_pattern_missing_fields(db, infer, pat_id, &body[pat_id])?;
let res = self.missing_fields(db, krate, substs, variant, missing_fields);
Some(res)