never executed always true always false
1 {-
2 (c) The University of Glasgow 2006
3 (c) The GRASP/AQUA Project, Glasgow University, 1992-1998
4
5 \section{Haskell abstract syntax definition}
6
7 This module glues together the pieces of the Haskell abstract syntax,
8 which is declared in the various \tr{Hs*} modules. This module,
9 therefore, is almost nothing but re-exporting.
10 -}
11
12 {-# LANGUAGE ConstraintKinds #-}
13 {-# LANGUAGE FlexibleContexts #-}
14 {-# LANGUAGE FlexibleInstances #-} -- For deriving instance Data
15 {-# LANGUAGE TypeFamilies #-}
16 {-# LANGUAGE UndecidableInstances #-} -- Wrinkle in Note [Trees That Grow]
17 -- in module Language.Haskell.Syntax.Extension
18 -- See Note [Language.Haskell.Syntax.* Hierarchy] for why not GHC.Hs.*
19 module Language.Haskell.Syntax (
20 module Language.Haskell.Syntax.Binds,
21 module Language.Haskell.Syntax.Decls,
22 module Language.Haskell.Syntax.Expr,
23 module Language.Haskell.Syntax.Lit,
24 module Language.Haskell.Syntax.Pat,
25 module Language.Haskell.Syntax.Type,
26 module Language.Haskell.Syntax.Extension,
27 ) where
28
29 import Language.Haskell.Syntax.Decls
30 import Language.Haskell.Syntax.Binds
31 import Language.Haskell.Syntax.Expr
32 import Language.Haskell.Syntax.Lit
33 import Language.Haskell.Syntax.Extension
34 import Language.Haskell.Syntax.Pat
35 import Language.Haskell.Syntax.Type
36
37 {-
38 Note [Language.Haskell.Syntax.* Hierarchy]
39 ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
40
41 Why are these modules not 'GHC.Hs.*', or some other 'GHC.*'? The answer
42 is that they are to be separated from GHC and put into another package,
43 in accordance with the final goals of Trees That Grow. (See Note [Trees
44 That Grow] in 'Language.Haskell.Syntax.Extension'.) In short, the
45 'Language.Haskell.Syntax.*' tree should be entirely GHC-independent.
46 GHC-specific stuff related to source-language syntax should be in
47 'GHC.Hs.*'.
48
49 We cannot move them to the separate package yet, but by giving them
50 names like so, we hope to remind others that the goal is to factor them
51 out, and therefore dependencies on the rest of GHC should never be
52 added, only removed.
53
54 For more details, see
55 https://gitlab.haskell.org/ghc/ghc/-/wikis/implementing-trees-that-grow
56 -}
57
58
59 -- TODO Add TTG parameter to 'HsModule' and move here.