Start on a DiagnosticProvider
implementation for Rust
Co-Authored-By: Nathan Sobo <nathan@zed.dev>
This commit is contained in:
parent
393009a05c
commit
a85e400b35
6 changed files with 138 additions and 10 deletions
|
@ -791,16 +791,24 @@ impl Workspace {
|
|||
{
|
||||
error!("failed to save item: {:?}, ", error);
|
||||
}
|
||||
|
||||
handle.update(&mut cx, |this, cx| {
|
||||
this.project.update(cx, |project, cx| project.diagnose(cx))
|
||||
});
|
||||
})
|
||||
.detach();
|
||||
}
|
||||
},
|
||||
);
|
||||
} else {
|
||||
cx.spawn(|_, mut cx| async move {
|
||||
cx.spawn(|this, mut cx| async move {
|
||||
if let Err(error) = cx.update(|cx| item.save(cx)).unwrap().await {
|
||||
error!("failed to save item: {:?}, ", error);
|
||||
}
|
||||
|
||||
this.update(&mut cx, |this, cx| {
|
||||
this.project.update(cx, |project, cx| project.diagnose(cx))
|
||||
});
|
||||
})
|
||||
.detach();
|
||||
}
|
||||
|
@ -832,6 +840,10 @@ impl Workspace {
|
|||
if let Err(error) = result {
|
||||
error!("failed to save item: {:?}, ", error);
|
||||
}
|
||||
|
||||
handle.update(&mut cx, |this, cx| {
|
||||
this.project.update(cx, |project, cx| project.diagnose(cx))
|
||||
});
|
||||
})
|
||||
.detach()
|
||||
}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue