Skip to content

Conversation

basetunnel
Copy link
Contributor

No description provided.

introduced: 9.8.1
---

Applying a term to a type (using @ notation) requires enabling the TypeApplication extension.
Copy link
Collaborator

Choose a reason for hiding this comment

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

Could you please quote the text of the error message somewhere? This would help search engines to find this page.

/tmp/foo.hs:3:5: error:
    Illegal visible type application ‘@Int’
      Perhaps you intended to use TypeApplications
  |
3 | x = read @Int "42"
  |     ^^^^^^^^^

Also it's worth to mention that TypeApplications is implied by GHC2021 / GHC2024 and with modern GHCs one has to specify Haskell2010 explicitly to trigger the error.

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

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants