Skip to content
GitLab
Projects Groups Snippets
  • /
  • Help
    • Help
    • Support
    • Community forum
    • Submit feedback
  • Sign in / Register
  • GHC GHC
  • Project information
    • Project information
    • Activity
    • Labels
    • Members
  • Repository
    • Repository
    • Files
    • Commits
    • Branches
    • Tags
    • Contributors
    • Graph
    • Compare
    • Locked Files
  • Issues 5,243
    • Issues 5,243
    • List
    • Boards
    • Service Desk
    • Milestones
    • Iterations
  • Merge requests 570
    • Merge requests 570
  • CI/CD
    • CI/CD
    • Pipelines
    • Jobs
    • Schedules
    • Test Cases
  • Deployments
    • Deployments
    • Releases
  • Analytics
    • Analytics
    • Value stream
    • CI/CD
    • Code review
    • Insights
    • Issue
    • Repository
  • Wiki
    • Wiki
  • Snippets
    • Snippets
  • Activity
  • Graph
  • Create a new issue
  • Jobs
  • Commits
  • Issue Boards
Collapse sidebar
  • Glasgow Haskell CompilerGlasgow Haskell Compiler
  • GHCGHC
  • Issues
  • #21826
Closed
Open
Issue created Jul 07, 2022 by sheaf@sheafMaintainer

Import error message for a type operator should suggest type keyword

I needed to import (~) from Data.Type.Equality, after the introduction of the -Wtype-equality-out-of-scope warning.

However, I tried to write

import Data.Type.Equality ( (~) )

instead of:

import Data.Type.Equality ( type (~) )

This caused the rather inscrutable error message:

 error:
    Module `Data.Type.Equality' does not export `(~)'

I think it would be much better if the error message noticed that there was a type operator by that name exported by Data.Type.Equality, and mentioned that I might have meant to use the type keyword to refer to it.

To upload designs, you'll need to enable LFS and have an admin enable hashed storage. More information
Assignee
Assign to
Time tracking