Add support for reexport operator suggestions
Nobody has claimed this yet.
- Dominant language
- Haskell
- Stars
- 1.6k
- Forks
- 210
- PR merge metrics
- No merged PRs in 30d
Description
I'm working on alternative Prelude where I reexport some useful things. And I would like to provide suggestions for users to not export some functions and operators from modules explicitly when they are using my prelude.
Consider the following .hlint-test.yaml file:
- warn: { name: "Use '>>>' from Relude"
, lhs: (Control.Category.>>>)
, rhs: (>>>)
}
When I have the following Test.hs file:
import Control.Category ((>>>))
import Relude
foo = (>>>)
everything works as expected and I see expected hint message:
Test.hs:4:7: Warning: Use '>>>' from Relude
Found:
(>>>)
Perhaps:
(>>>)
But when I'm applying operator to arguments:
import Control.Category ((>>>))
import Relude
foo = id >>> id
I see only No hints. Though, it would be really great if I can observe the hint in the second case as well!
Contributor guide
No contributing guide indexed for this repository
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
Reproduce the behavior using the .hlint-test.yaml and Test.hs examples in the issue, comparing the parenthesized operator with id >>> id. Trace how HLint handles operator suggestions in applications. Done means the reexport suggestion is emitted for the applied-operator case as well as the standalone case.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- haskell
- Domain
- devtools
- Issue type
- Feature
- Difficulty
- 4/5
- Estimated time
- 3-5 days
- Activity status
- Stale
- Clarity
- Mostly clear
- Newbie friendliness
- 35/100