mirror of
https://github.com/rust-lang/rust-analyzer.git
synced 2025-09-28 11:20:54 +00:00
Fix a mistake in condition
This commit is contained in:
parent
4fe18a6fb5
commit
e5c38558f5
@ -550,7 +550,7 @@ pub fn record_literal_missing_fields(
|
||||
) -> Option<(VariantId, Vec<LocalFieldId>, /*has spread expr*/ bool)> {
|
||||
let (fields, has_spread_expr, has_ellipsis) = match expr {
|
||||
Expr::RecordLit { fields, spread, .. } => {
|
||||
(fields, matches!(spread, Spread::Base(_)), matches!(spread, Spread::Yes))
|
||||
(fields, !matches!(spread, Spread::Base(_)), matches!(spread, Spread::Yes))
|
||||
}
|
||||
_ => return None,
|
||||
};
|
||||
|
@ -202,7 +202,6 @@ fn check_impl(
|
||||
for def in defs {
|
||||
let (body, body_source_map) = db.body_with_source_map(def);
|
||||
let inference_result = db.infer(def);
|
||||
dbg!(&inference_result);
|
||||
|
||||
for (pat, mut ty) in inference_result.type_of_pat.iter() {
|
||||
if let Pat::Bind { id, .. } = body.pats[pat] {
|
||||
|
Loading…
x
Reference in New Issue
Block a user