14. GHC Language Features¶
- 14.1. Language options
- 14.2. Unboxed types and primitive operations
- 14.3. Syntactic extensions
- 14.3.1. Unicode syntax
- 14.3.2. The magic hash
- 14.3.3. Negative literals
- 14.3.4. Fractional looking integer literals
- 14.3.5. Binary integer literals
- 14.3.6. Hexadecimal floating point literals
- 14.3.7. Numeric underscores
- 14.3.8. Pattern guards
- 14.3.9. View patterns
- 14.3.10. n+k patterns
- 14.3.11. The recursive do-notation
- 14.3.12. Applicative do-notation
- 14.3.13. Parallel List Comprehensions
- 14.3.14. Generalised (SQL-like) List Comprehensions
- 14.3.15. Monad comprehensions
- 14.3.16. New monadic failure desugaring mechanism
- 14.3.17. Rebindable syntax and the implicit Prelude import
- 14.3.18. Postfix operators
- 14.3.19. Tuple sections
- 14.3.20. Lambda-case
- 14.3.21. Empty case alternatives
- 14.3.22. Multi-way if-expressions
- 14.3.23. Local Fixity Declarations
- 14.3.24. Import and export extensions
- 14.3.25. More liberal syntax for function arguments
- 14.3.26. Summary of stolen syntax
- 14.4. Extensions to data types and type synonyms
- 14.4.1. Data types with no constructors
- 14.4.2. Data type contexts
- 14.4.3. Infix type constructors, classes, and type variables
- 14.4.4. Type operators
- 14.4.5. Liberalised type synonyms
- 14.4.6. Existentially quantified data constructors
- 14.4.7. Declaring data types with explicit constructor signatures
- 14.4.8. Generalised Algebraic Data Types (GADTs)
- 14.5. Extensions to the record system
- 14.6. Extensions to the “deriving” mechanism
- 14.6.1. Deriving instances for empty data types
- 14.6.2. Inferred context for deriving clauses
- 14.6.3. Stand-alone deriving declarations
- 14.6.4. Deriving instances of extra classes (
Data
, etc.) - 14.6.5. Generalised derived instances for newtypes
- 14.6.6. Deriving any other class
- 14.6.7. Deriving strategies
- 14.6.8. Deriving via
- 14.7. Pattern synonyms
- 14.8. Class and instances declarations
- 14.9. Type families
- 14.10. Datatype promotion
- 14.11. Kind polymorphism
- 14.11.1. Overview of kind polymorphism
- 14.11.2. Overview of Type-in-Type
- 14.11.3. Principles of kind inference
- 14.11.4. Inferring the order of variables in a type/class declaration
- 14.11.5. Complete user-supplied kind signatures and polymorphic recursion
- 14.11.6. Standalone kind signatures and polymorphic recursion
- 14.11.7. Standalone kind signatures and declaration headers
- 14.11.8. Kind inference in closed type families
- 14.11.9. Kind inference in class instance declarations
- 14.11.10. Kind inference in type signatures
- 14.11.11. Explicit kind quantification
- 14.11.12. Implicit quantification in type synonyms and type family instances
- 14.11.13. Kind-indexed GADTs
- 14.11.14. Higher-rank kinds
- 14.11.15. Constraints in kinds
- 14.11.16. The kind
Type
- 14.11.17. Inferring dependency in datatype declarations
- 14.11.18. Inferring dependency in user-written
forall
s - 14.11.19. Kind defaulting without
PolyKinds
- 14.11.20. Pretty-printing in the presence of kind polymorphism
- 14.12. Levity polymorphism
- 14.13. Type-Level Literals
- 14.14. Equality constraints, Coercible, and the kind Constraint
- 14.15. Quantified constraints
- 14.16. Extensions to type signatures
- 14.17. Lexically scoped type variables
- 14.18. Bindings and generalisation
- 14.19. Visible type application
- 14.20. Implicit parameters
- 14.21. Arbitrary-rank polymorphism
- 14.22. Impredicative polymorphism
- 14.23. Typed Holes
- 14.24. Partial Type Signatures
- 14.25. Custom compile-time errors
- 14.26. Deferring type errors to runtime
- 14.27. Template Haskell
- 14.28. Arrow notation
- 14.29. Bang patterns and Strict Haskell
- 14.30. Assertions
- 14.31. Static pointers
- 14.32. Pragmas
- 14.32.1.
LANGUAGE
pragma - 14.32.2.
OPTIONS_GHC
pragma - 14.32.3.
INCLUDE
pragma - 14.32.4.
WARNING
andDEPRECATED
pragmas - 14.32.5.
MINIMAL
pragma - 14.32.6.
INLINE
andNOINLINE
pragmas - 14.32.7.
LINE
pragma - 14.32.8.
COLUMN
pragma - 14.32.9.
RULES
pragma - 14.32.10.
SPECIALIZE
pragma - 14.32.11.
SPECIALIZE
instance pragma - 14.32.12.
UNPACK
pragma - 14.32.13.
NOUNPACK
pragma - 14.32.14.
SOURCE
pragma - 14.32.15.
COMPLETE
pragmas - 14.32.16.
OVERLAPPING
,OVERLAPPABLE
,OVERLAPS
, andINCOHERENT
pragmas
- 14.32.1.
- 14.33. Rewrite rules
- 14.34. Special built-in functions
- 14.35. Generic classes
- 14.36. Generic programming
- 14.37. Roles
- 14.38. HasCallStack
- 14.39. Concurrent and Parallel Haskell
- 14.40. Safe Haskell