Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Remove unused Semigroup imports. #5673

Merged
merged 1 commit into from
Nov 9, 2018
Merged

Conversation

DavidEichmann
Copy link
Contributor

Due to a bug in ghc, some unused imports do not yield warnings.
This commit will remove such unused imports in preparation for
the ghc bug fix (see https://ghc.haskell.org/trac/ghc/ticket/13064).


Please include the following checklist in your PR:

  • Patches conform to the coding conventions.
  • Any changes that could be relevant to users have been recorded in the changelog.
  • The documentation has been updated, if necessary.
  • If the change is docs-only, [ci skip] is used to avoid triggering the build bots.

Testing: Building in CI should be sufficient here.

Copy link
Collaborator

@phadej phadej left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM, let's merge once CI passes

@phadej phadej changed the title Remove unused imports. Remove unused Semigroup imports. Nov 8, 2018
@@ -117,7 +118,12 @@ import Control.DeepSeq (NFData (..))
import Data.Data (Data)
import Data.Typeable (Typeable)
import Distribution.Compat.Binary (Binary (..))
import Distribution.Compat.Semigroup (Semigroup (..), gmappend, gmempty)
#if !MINVER_base_411 && MINVER_base_48
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

don't we need to import Semigroup always before base-4.11, let's see what travis says

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I've made quite a lot of these changes today, so my head is spinning. I think you're right, I'm having a closer look.

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

On closer investigation, import Distribution.Compat.Semigroup (Semigroup (..)) is used because it is rexported as Semigroup (..). Note that Semigroup (..) from Distribution.Compat.Semigroup contains only Semigroup((<>)). The import is still redundant (in newer base version) because the default Prelude is imported (non-qualified) which exports Semigroup((<>)).

I'll try and resolve the warning by hiding Semigroup((<>)) from prelude.

haskell-pushbot pushed a commit to haskell-pushbot/cabal-binaries that referenced this pull request Nov 8, 2018
"url":"pull/5673",
"account":"haskell",
"repo":"cabal",
"commit": "c4565cdc8c010c8866f5f2db271e5d7d09b6f8a5",
"tag":"linux-7.10.3"
}
haskell-pushbot pushed a commit to haskell-pushbot/cabal-binaries that referenced this pull request Nov 8, 2018
"url":"pull/5673",
"account":"haskell",
"repo":"cabal",
"commit": "c4565cdc8c010c8866f5f2db271e5d7d09b6f8a5",
"tag":"linux-8.0.2"
}
haskell-pushbot pushed a commit to haskell-pushbot/cabal-binaries that referenced this pull request Nov 8, 2018
"url":"pull/5673",
"account":"haskell",
"repo":"cabal",
"commit": "c4565cdc8c010c8866f5f2db271e5d7d09b6f8a5",
"tag":"linux-8.2.2"
}
haskell-pushbot pushed a commit to haskell-pushbot/cabal-binaries that referenced this pull request Nov 8, 2018
"url":"pull/5673",
"account":"haskell",
"repo":"cabal",
"commit": "c4565cdc8c010c8866f5f2db271e5d7d09b6f8a5",
"tag":"linux-8.4.4"
}
haskell-pushbot pushed a commit to haskell-pushbot/cabal-binaries that referenced this pull request Nov 8, 2018
"url":"pull/5673",
"account":"haskell",
"repo":"cabal",
"commit": "c4565cdc8c010c8866f5f2db271e5d7d09b6f8a5",
"tag":"linux-8.6.2"
}
haskell-pushbot pushed a commit to haskell-pushbot/cabal-binaries that referenced this pull request Nov 8, 2018
"url":"pull/5673",
"account":"haskell",
"repo":"cabal",
"commit": "c4565cdc8c010c8866f5f2db271e5d7d09b6f8a5",
"tag":"linux-8.4.4-fdebug-expensive-assertions"
}
haskell-pushbot pushed a commit to haskell-pushbot/cabal-binaries that referenced this pull request Nov 8, 2018
"url":"pull/5673",
"account":"haskell",
"repo":"cabal",
"commit": "c4565cdc8c010c8866f5f2db271e5d7d09b6f8a5",
"tag":"osx-7.10.3"
}
haskell-pushbot pushed a commit to haskell-pushbot/cabal-binaries that referenced this pull request Nov 8, 2018
"url":"pull/5673",
"account":"haskell",
"repo":"cabal",
"commit": "c4565cdc8c010c8866f5f2db271e5d7d09b6f8a5",
"tag":"osx-8.0.2"
}
Due to a bug in ghc, some unused imports do not yield warnings.
This commit will remove such unused imports in preparation for
the ghc bug fix (see https://ghc.haskell.org/trac/ghc/ticket/13064).
haskell-pushbot pushed a commit to haskell-pushbot/cabal-binaries that referenced this pull request Nov 8, 2018
"url":"pull/5673",
"account":"haskell",
"repo":"cabal",
"commit": "016c7ee08badc9664be86784746097755802cde1",
"tag":"linux-7.6.3"
}
haskell-pushbot pushed a commit to haskell-pushbot/cabal-binaries that referenced this pull request Nov 8, 2018
"url":"pull/5673",
"account":"haskell",
"repo":"cabal",
"commit": "016c7ee08badc9664be86784746097755802cde1",
"tag":"linux-7.8.4"
}
haskell-pushbot pushed a commit to haskell-pushbot/cabal-binaries that referenced this pull request Nov 8, 2018
"url":"pull/5673",
"account":"haskell",
"repo":"cabal",
"commit": "016c7ee08badc9664be86784746097755802cde1",
"tag":"linux-7.10.3"
}
haskell-pushbot pushed a commit to haskell-pushbot/cabal-binaries that referenced this pull request Nov 8, 2018
"url":"pull/5673",
"account":"haskell",
"repo":"cabal",
"commit": "016c7ee08badc9664be86784746097755802cde1",
"tag":"linux-8.0.2"
}
haskell-pushbot pushed a commit to haskell-pushbot/cabal-binaries that referenced this pull request Nov 8, 2018
"url":"pull/5673",
"account":"haskell",
"repo":"cabal",
"commit": "016c7ee08badc9664be86784746097755802cde1",
"tag":"linux-8.2.2"
}
haskell-pushbot pushed a commit to haskell-pushbot/cabal-binaries that referenced this pull request Nov 8, 2018
"url":"pull/5673",
"account":"haskell",
"repo":"cabal",
"commit": "016c7ee08badc9664be86784746097755802cde1",
"tag":"linux-8.6.2"
}
haskell-pushbot pushed a commit to haskell-pushbot/cabal-binaries that referenced this pull request Nov 8, 2018
"url":"pull/5673",
"account":"haskell",
"repo":"cabal",
"commit": "016c7ee08badc9664be86784746097755802cde1",
"tag":"linux-8.4.4-fdebug-expensive-assertions"
}
haskell-pushbot pushed a commit to haskell-pushbot/cabal-binaries that referenced this pull request Nov 8, 2018
"url":"pull/5673",
"account":"haskell",
"repo":"cabal",
"commit": "016c7ee08badc9664be86784746097755802cde1",
"tag":"osx-7.8.4"
}
haskell-pushbot pushed a commit to haskell-pushbot/cabal-binaries that referenced this pull request Nov 8, 2018
"url":"pull/5673",
"account":"haskell",
"repo":"cabal",
"commit": "016c7ee08badc9664be86784746097755802cde1",
"tag":"osx-8.0.2"
}
haskell-pushbot pushed a commit to haskell-pushbot/cabal-binaries that referenced this pull request Nov 8, 2018
"url":"pull/5673",
"account":"haskell",
"repo":"cabal",
"commit": "016c7ee08badc9664be86784746097755802cde1",
"tag":"linux-8.4.4"
}
@DavidEichmann
Copy link
Contributor Author

I see 1 job has failed in CI due to a timeout. This seems to be the case for many recent PRs.

@23Skidoo
Copy link
Member

23Skidoo commented Nov 9, 2018

Well, it still verified that lib:Cabal builds, also the Linux 7.10.3 build passed.

@23Skidoo 23Skidoo merged commit 47e2831 into haskell:master Nov 9, 2018
@23Skidoo
Copy link
Member

23Skidoo commented Nov 9, 2018

Merged, thanks!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants