lspitzner / lspitzner/brittany

Consider several elements per line in long lists of small elements

Open
#302 2 comments 1 reaction 0 assignees View on GitHub

Nobody has claimed this yet.

hs:lists question
Dominant language
Haskell
Stars
686
Forks
69
PR merge metrics
No merged PRs in 30d

Description

It might be hard to come up with a consistent rule for this. Nevertheless I think the former is much easier to read (and doesn't eat a whole page in my editor)

foo =
  [ 0.0, -0.5, 1.0, 1.0, 1.0
  , 0.5, 0.5, 0.0, 1.0, 0.0
  , -0.5, 0.5, 0.0, 0.0, 1.0
  , 1.0, 0.0, 0.0, 0.0, 0.0
  ]

foo =
  [ 0.0
  , -0.5
  , 1.0
  , 1.0
  , 1.0
  , 0.5
  , 0.5
  , 0.0
  , 1.0
  , 0.0
  , -0.5
  , 0.5
  , 0.0
  , 0.0
  , 1.0
  , 1.0
  , 0.0
  , 0.0
  , 0.0
  , 0.0
  ]

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

The issue provides examples of preferred and current list formatting but names no files, tests, or entry points. Start by locating the formatter logic for lists of small elements and determine whether a consistent line-grouping rule is feasible. Done would require an agreed formatting rule plus regression coverage for the shown cases.

Written by the indexing model from the issue text.

Assessment

Tech stack
haskell
Domain
tooling
Issue type
Feature
Difficulty
5/5
Estimated time
Over a week
Activity status
Stale
Clarity
Needs clarification
Newbie friendliness
25/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.