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

"The import of module is redundant" should be "... is unused" in certain cases #2671

Open
marick opened this issue Feb 17, 2017 · 2 comments

Comments

@marick
Copy link

marick commented Feb 17, 2017

Suggest the word "redundant" in the above message be replaced with "unused".

As I newbie, I typed the following from the Purescript book:

module Data.AddressBook where

import Prelude

import Control.Plus (empty)
import Data.List (List(..), filter, head)
import Data.Maybe (Maybe)

Because I don't trust my typing, I ran pulp. I saw messages like this:

    The import of module Control.Plus is redundant

Although "redundant" can have the meaning "unnecessary", I think the sense "characterized by unnecessary repetition" is more common. I certainly assumed that the message somehow meant that maybe Control.Plus was already imported by Prelude.

I think Elm's equivalent message is as accurate and less likely to mislead: Module List is unused.

@hdgarrood
Copy link
Contributor

👍 Just to make sure we're all on the same page, do we all agree that the import of Data.Functor should continue to be described as 'redundant' in the following set of imports?

import Prelude
import Data.Functor (map)

@paf31 paf31 changed the title "The import of module Math is redundant" could be written more clearly. "The import of module is redundant" should be "... is unused" in certain cases Feb 17, 2017
@paf31 paf31 modified the milestones: Approved, Ideas Feb 17, 2017
@matthewleon
Copy link
Contributor

matthewleon commented Feb 17, 2017

@hdgarrood what would be even friendlier, in the case you bring up, would be an explanation as to why it is redundant... "Data.Functor is subsumed by imported Prelude" or something along those lines.

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

No branches or pull requests

4 participants