haskell / haskell/hoopl

Hoopl collection classes could use enummapset?

Open
#53 6 comments 0 reactions 0 assignees View on GitHub
Dominant language
Haskell
Stars
77
Forks
30
PR merge metrics
No merged PRs in 30d

Description

I have found myself using https://hackage.haskell.org/package/enummapset a lot in my code. It provides wrappers around `IntSet`/`IntMap` that uses `Enum` rather than `Int`, which allows for better type safety.

Now I am doing more work with Hoopl in my project and it lacks certain useful functions from `IntMap`. I am looking at `restrictKeys` at the moment. I am trying to wrap my head around how to implement it, but I also realize that in some way this collection code in Hoopl is just the same thing as is also provided by enummapset. I was thinking that maybe it would better to migrate the code in Hoopl to make use of enummapset rather than rolling its own duplicate that tends to be out of date (I have added some missing functions before).

I wonder what the maintainer and people using Hoopl think about this?

Contributor guide

No contributing guide indexed for this repository

Research direction

Start by reading Hoopl's collection code and comparing it with the enummapset package, focusing on the missing restrictKeys functionality and the existing IntMap/IntSet wrappers. Review the discussion and determine whether migrating Hoopl to enummapset is appropriate; done requires an agreed migration direction and a complete, compatible collection implementation.

Written by the indexing model from the issue text.

Assessment

Tech stack
haskell
Domain
compilers
Issue type
Refactor
Difficulty
5/5
Estimated time
Over a week
Activity status
Stale
Clarity
Mostly clear
Newbie friendliness
25/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.