-
-
Notifications
You must be signed in to change notification settings - Fork 22
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Visual Studio 2017/2019 support? #23
Comments
I don't know much about VS extensibility but... TBF, I wouldn't recommend doing this unless:
In Ionide/FSAC, because we control everything we can easily pass In the command-line tool, we just create own |
As mentioned by Phillip during F# Conf Q&A - hopefully, in the long term this will be solved by VS adapting FsAutoComplete as a base for F# editor tooling support. |
Suggestions API isn't too bad, but the tagging, error list and updates, it turns out are a bit more involved that that. As @Krzysztof-Cieslak said, the biggest hurdle to perf right now is that VF# uses its own checker, and not FCS. Even if VS adapts FCS, there would need to be VSIX infrastructure for this. We'd get text tagging, warnings in the error list, code fix suggestions etc., for free. To start with, taking a perf hit is probably better than nothing. (I guess?) How does Ionide currently 'discover' the various analyzers referenced by the project? Any suggestions a TODO list to integrate this? |
FSAC (which Ionide uses) has a package reference to the FSharp.Analyzers.SDK.Client in this repo, then calls this member to do the actual scanning/registration at startup and when the configuration changes. Then, as files are checked in the background, there's an event inside FSAC that's fired and the configured analyzers are run on the file using this member. |
Thank you for the prompt response. |
I've started an RFC discussing how to get F# analyzers incorporated into FSHarp.Compiler.Service, i.e. available in all F# tooling https://github.com/fsharp/fslang-design/blob/master/tooling/FST-1033-analyzers.md The main issue is binary compatibility for the information being drawn from the FCS API, so analyzers can be binary compatible components. |
See also #28 |
@dsyme Can we have fixes as lazy (similar to FSharpLint)?
Fixes are only needed when a user opens a CodeFix suggestion. |
Yes I've mentioned that in the RFC |
I find the Fix type of I found Maybe provide a DU: Either the strings, or something more AST-like? |
Yes, fixes shouldn't be provided as string - in current implementation it's the result of me not having enough time to implement AST based version rather than design choice |
I know this project is now under Ionide, but there has been questions to support the old Visual Studio.
It wouldn't be so hard to do by combining code in this SDK and use this to do rest:
http://www.fssnip.net/7SQ/title/Visual-Studio-2017-extension-Displaying-Light-Bulb-Suggestions-
But source-code-wise, would you accept PR containing dependences to
Microsoft.VisualStudio.*.dll
?Or what should be done, a new project with paket-references to files here?
The text was updated successfully, but these errors were encountered: