문제

Is there a tool that detects unused code in F# programs?

Tools for F# have been discussed from time to time, but it has been a while since this question:

Are there any support tools like coderush or resharper for F#?

도움이 되었습니까?

해결책

I don't know of any tool that performs dead code analysis for F# right now.

That said, the recently-released FSharp.Compiler.Service project certainly makes implementing such tools easier now.

A while back, one or two of the JetBrains developers experimented with a ReSharper language service for F#, but I don't think they ever got to the point where it was usable in production. Maybe now that FSharp.Compiler.Service is available, perhaps work can start up again. If you want to see their work: https://github.com/JetBrains/FSharper

다른 팁

Use the following project settings:

Visual Studio > Solution >
    Project > Build > General > Other flags > --warnon:1182

This will warn on unused functions and values when code gets compiled.

라이센스 : CC-BY-SA ~와 함께 속성
제휴하지 않습니다 StackOverflow
scroll top