Skip to content

GitLab

  • Projects
  • Groups
  • Snippets
  • Help
    • Loading...
  • Help
    • Help
    • Support
    • Community forum
    • Submit feedback
  • Sign in / Register
P
prime
  • Project overview
    • Project overview
    • Details
    • Activity
    • Releases
  • Repository
    • Repository
    • Files
    • Commits
    • Branches
    • Tags
    • Contributors
    • Graph
    • Compare
    • Locked Files
  • Issues 129
    • Issues 129
    • List
    • Boards
    • Labels
    • Service Desk
    • Milestones
    • Iterations
  • Merge Requests 0
    • Merge Requests 0
  • Requirements
    • Requirements
    • List
  • Security & Compliance
    • Security & Compliance
    • Dependency List
    • License Compliance
  • Operations
    • Operations
    • Incidents
  • Analytics
    • Analytics
    • Code Review
    • Insights
    • Issue
    • Repository
    • Value Stream
  • Wiki
    • Wiki
  • Snippets
    • Snippets
  • Members
    • Members
  • Collapse sidebar
  • Activity
  • Graph
  • Create a new issue
  • Commits
  • Issue Boards
  • Haskell
  • prime
  • Wiki
  • existential quantifier

Last edited by john@repetae.net Feb 15, 2006
Page history New page

existential quantifier

Existential Quantifier

this means supporting the 'exists' quantifier as creating existential types much the same way 'forall' can be used in ghc. An example would be

type Any = exists a . Typeable a => a

sameType :: Any -> Any -> Bool
sameType x y = typeOf x == typeOf y

When existentials appear in the contravarient position such as above, they can be desugared into rank-n types with foralls. if existentials are allowed in the covarient position, then support for FirstClassExistentials? is needed.

Support

Jhc currently supports the existential syntax anywhere a type is accepted, but will report an error if one is used in a covariant position with the exception of when it is a component of a data type.

Clone repository
Wiki

Title Index