ndmitchell / ndmitchell/hlint

Sometimes hint output includes a lot of junk

Open
#80 0 comments 0 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

Dominant language
Haskell
Stars
1.6k
Forks
210
PR merge metrics
No merged PRs in 30d

Description

Given:

main = do
    let a = 1
    let a = 2
    let a = 3
    let a = 4
    let a = 5
    let a = 6
    let a = 7
    let a = 8
    let a = 9
    let a = (f 10)
    let a = 11
    let a = 12
    let a = 13
    let a = 14
    let a = 15
    let a = 16
    let a = 17
    let a = 18
    let a = 19
    return ()

The remove bracket hint prints out all the additional a values. That can be a fantastic amount of complex code. A better approach would be to format both the input and the output as the user wrote it, and just include the line above/line below for context. Jumping to a whole expression is excessive.

Contributor guide

No contributing guide indexed for this repository

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Research direction

Reproduce the remove bracket hint using the Haskell snippet in the issue and trace the hint-output entry point. Compare the current output with the source-line context described in the report; done means the hint no longer dumps unrelated bindings while retaining useful nearby context.

Written by the indexing model from the issue text.

Assessment

Tech stack
haskell
Domain
tooling
Issue type
Bug
Difficulty
4/5
Estimated time
3-5 days
Activity status
Stale
Clarity
Mostly clear
Newbie friendliness
40/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.