Add support for compilation end code fix. - #1132
Conversation
now code fix should support diagnostics from compilation end action. a few options are added to test experience which can be changed from Tools/Options/Roslyn/Diagnostic pane.
|
@mavasani @shyamnamboodiripad @srivatsn @tmeschter @JohnHamby @jmarolf can you take a look? |
|
The code fix is still synchronously computed on Ctrl + Dot right? So until we have asynchronous light bulb support, Ctrl + Dot will be slower if user has any such fixer enabled? We should probably document this somewhere in the fixer API (probably on the property fetching supported diagnostic IDs). |
There was a problem hiding this comment.
We do a state.Remove(project.Id) at the start of method, but persist only document diagnostics data here, not project diagnostics with no location? Where are those persisted?
There was a problem hiding this comment.
kv.Key == null is for project.
|
👍 |
There was a problem hiding this comment.
"Heuristic" is the expected spelling. What is the heuristic? How reliable is it?
There was a problem hiding this comment.
@JohnHamby heuristic is that, if there is existing compilation end diagnostic, we show code fix for it, otherwise, we won't.
but this behavior is controlled by an option you can change from Tools/Options/Roslyn/Diagnostics
until we have async support from platform, we probably need to test several different experiences. this is just one of them.
|
current heuristic is we only support compilation end code fix when it is already reported. otherwise, no. we also have an option to turn that heuristic off so that we always block user on ctrl+.. (in Tools\Options) we also have an option to turn off compilation end code fix (in Tools\Options) is this to test different behavior until we have async LB support from platform. |
|
@JohnHamby @srivatsn @shyamnamboodiripad can one of you sign off? |
There was a problem hiding this comment.
Nit: capitalize the first word in every sentence.
now code fix should support diagnostics from compilation end action.
a few options are added to test experience which can be changed from Tools/Options/Roslyn/Diagnostic pane.