fsprojects / fsprojects/FSharpLint
Feature Request: favour typed Async.Ignore
Nobody has claimed this yet.
- Dominant language
- F#
- Stars
- 327
- Forks
- 74
- PR merge metrics
- No merged PRs in 30d
Description
Description
There's already a rule to favor typed ignore instead of the non-typed version,
the same logic is applicable to Async.Ignore, so maybe FSharpLint should
also throw a warning for usage of non-typed Async.Ignore.
Expected behavior
member self.ConnectToDirectory() =
async {
return 1
}
do! self.ConnectToDirectory() |> Async.Ignore
In this sample FSharpLint should throw a warning to ask user
to use typed Async.Ignore like this:
do! self.ConnectToDirectory() |> Async.Ignore<int>
Actual behavior
FSharpLint doesn't throw any warning.
Contributor guide
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
Research direction
Start by finding the existing lint rule that favors typed ignore and inspect how its checks and tests are organized. Add equivalent coverage for non-typed Async.Ignore, then verify that the sample usage produces a warning requesting typed Async.Ignore.
Written by the indexing model from the issue text.
Assessment
- Domain
- tooling
- Issue type
- Feature
- Difficulty
- 3/5
- Estimated time
- 1-2 days
- Activity status
- Stale
- Clarity
- Mostly clear
- Newbie friendliness
- 45/100