haskell / haskell/stylish-haskell

[bug] module_header: Export list is sorted but individual elements on that list are not sorted

Open
#360 0 comments 0 reactions 0 assignees View on GitHub
Dominant language
Haskell
Stars
1k
Forks
153
PR merge metrics
No merged PRs in 30d

Description

Example in https://github.com/input-output-hk/ouroboros-network/blob/master/ouroboros-consensus-cardano/src/Ouroboros/Consensus/Cardano/Block.hs#L19

# Example

## Input
```
module Ouroboros.Consensus.Cardano.Block (
HardForkBlock (
BlockByron
, BlockShelley
, BlockAllegra
, BlockMary
)
, CardanoBlock) where
```

## Expected

```
module Ouroboros.Consensus.Cardano.Block (
CardanoBlock
, HardForkBlock (BlockAllegra, BlockByron, BlockMary, BlockShelley)
) where
```

## Actual

```
module Ouroboros.Consensus.Cardano.Block (
CardanoBlock
, HardForkBlock (BlockByron, BlockShelley, BlockAllegra, BlockMary)
) where
```

Contributor guide

No contributing guide indexed for this repository

Research direction

Start with the module_header formatting logic and reproduce the issue using ouroboros-consensus-cardano/src/Ouroboros/Consensus/Cardano/Block.hs at line 19. Done means nested elements in an export list are sorted alphabetically, matching the expected output shown here.

Written by the indexing model from the issue text.

Assessment

Tech stack
haskell
Domain
tooling
Issue type
Bug
Difficulty
3/5
Estimated time
1-2 days
Activity status
Stale
Clarity
Clearly specified
Newbie friendliness
52/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.