Remove Hoopl.Unique
ClosedPublic

Authored by michalt on Jan 21 2018, 8:08 AM.

Details

Summary

Reasons to remove:

  • It's confusing - we already have a widely used Unique module in basicTypes/ that defines a newtype called Unique
  • Hoopl.Unique is not actually used much

I've also moved the Unique{Map,Set} from Hoopl.Unique to
Hoopl.Collections to keep things together. But that module is also a
bit funny - it defines two type-classes that have only one instance
each. So we should probably either remove them or use them more
widely... In any case, that will be a separate change.

Signed-off-by: Michal Terepeta <michal.terepeta@gmail.com>

Test Plan

./validate

Diff Detail

Repository
rGHC Glasgow Haskell Compiler
Lint
Automatic diff as part of commit; lint not applicable.
Unit
Automatic diff as part of commit; unit tests not applicable.
michalt created this revision.Jan 21 2018, 8:08 AM
michalt added a subscriber: kavon.Jan 21 2018, 8:09 AM
bgamari added inline comments.Jan 21 2018, 11:03 AM
compiler/cmm/Hoopl/Label.hs
29–30

This is now slightly confusing, no?

michalt updated this revision to Diff 15174.Jan 21 2018, 12:13 PM

Rename uniqueToLabel to mkHooplLabel

michalt marked an inline comment as done.Jan 21 2018, 12:14 PM
michalt added inline comments.
compiler/cmm/Hoopl/Label.hs
29–30

Oops. Forgot to update this. Thanks!

bgamari accepted this revision.Jan 21 2018, 2:20 PM

Looks reasonable to me. Thanks!

This revision is now accepted and ready to land.Jan 21 2018, 2:20 PM
This revision was automatically updated to reflect the committed changes.