File tree 3 files changed +8
-0
lines changed
src/tools/rust-analyzer/crates/rust-analyzer/src
3 files changed +8
-0
lines changed Original file line number Diff line number Diff line change @@ -460,6 +460,11 @@ impl GlobalState {
460
460
}
461
461
}
462
462
463
+ // FIXME: `workspace_structure_change` is computed from `should_refresh_for_change` which is
464
+ // path syntax based. That is not sufficient for all cases so we should lift that check out
465
+ // into a `QueuedTask`, see `handle_did_save_text_document`.
466
+ // Or maybe instead of replacing that check, kick off a semantic one if the syntactic one
467
+ // didn't find anything (to make up for the lack of precision).
463
468
{
464
469
if !matches ! ( & workspace_structure_change, Some ( ( .., true ) ) ) {
465
470
_ = self
Original file line number Diff line number Diff line change @@ -158,6 +158,8 @@ pub(crate) fn handle_did_save_text_document(
158
158
. map ( |cfg| cfg. files_to_watch . iter ( ) . map ( String :: as_str) . collect :: < Vec < & str > > ( ) )
159
159
. unwrap_or_default ( ) ;
160
160
161
+ // FIXME: We should move this check into a QueuedTask and do semantic resolution of
162
+ // the files. There is only so much we can tell syntactically from the path.
161
163
if reload:: should_refresh_for_change ( path, ChangeKind :: Modify , additional_files) {
162
164
state. fetch_workspaces_queue . request_op (
163
165
format ! ( "workspace vfs file change saved {path}" ) ,
Original file line number Diff line number Diff line change @@ -105,6 +105,7 @@ pub(crate) enum Task {
105
105
FetchWorkspace ( ProjectWorkspaceProgress ) ,
106
106
FetchBuildData ( BuildDataProgress ) ,
107
107
LoadProcMacros ( ProcMacroProgress ) ,
108
+ // FIXME: Remove this in favor of a more general QueuedTask, see `handle_did_save_text_document`
108
109
BuildDepsHaveChanged ,
109
110
}
110
111
You can’t perform that action at this time.
0 commit comments