GhcPlugins.hs 2.53 KB
Newer Older
1 2 3 4 5 6
{-# OPTIONS_GHC -fno-warn-duplicate-exports #-}

-- | This module is not used by GHC itself.  Rather, it exports all of
-- the functions and types you are likely to need when writing a
-- plugin for GHC. So authors of plugins can probably get away simply
-- with saying "import GhcPlugins".
7
--
8 9 10
-- Particularly interesting modules for plugin writers include
-- "CoreSyn" and "CoreMonad".
module GhcPlugins(
Adam Gundry's avatar
Adam Gundry committed
11
        module Plugins,
12
        module RdrName, module OccName, module Name, module Var, module Id, module IdInfo,
Adam Gundry's avatar
Adam Gundry committed
13
        module CoreMonad, module CoreSyn, module Literal, module DataCon,
14 15 16
        module CoreUtils, module MkCore, module CoreFVs, module CoreSubst,
        module Rules, module Annotations,
        module DynFlags, module Packages,
17
        module Module, module Type, module TyCon, module Coercion,
18
        module TysWiredIn, module HscTypes, module BasicTypes,
19
        module VarSet, module VarEnv, module NameSet, module NameEnv,
20
        module UniqSet, module UniqFM, module FiniteMap,
21
        module Util, module GHC.Serialized, module SrcLoc, module Outputable,
22
        module UniqSupply, module Unique, module FastString
23 24 25
    ) where

-- Plugin stuff itself
Adam Gundry's avatar
Adam Gundry committed
26
import Plugins
27 28 29 30 31 32 33 34 35 36

-- Variable naming
import RdrName
import OccName  hiding  ( varName {- conflicts with Var.varName -} )
import Name     hiding  ( varName {- reexport from OccName, conflicts with Var.varName -} )
import Var
import Id       hiding  ( lazySetIdInfo, setIdExported, setIdNotExported {- all three conflict with Var -} )
import IdInfo

-- Core
Adam Gundry's avatar
Adam Gundry committed
37
import CoreMonad
38 39 40 41 42 43
import CoreSyn
import Literal
import DataCon
import CoreUtils
import MkCore
import CoreFVs
44 45
import CoreSubst hiding( substTyVarBndr, substCoVarBndr, extendCvSubst )
       -- These names are also exported by Type
46 47 48 49 50 51 52 53 54 55 56 57

-- Core "extras"
import Rules
import Annotations

-- Pipeline-related stuff
import DynFlags
import Packages

-- Important GHC types
import Module
import Type     hiding {- conflict with CoreSubst -}
58
                ( substTy, extendTvSubst, extendTvSubstList, isInScope )
59
import Coercion hiding {- conflict with CoreSubst -}
60
                ( substCo )
61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78
import TyCon
import TysWiredIn
import HscTypes
import BasicTypes hiding ( Version {- conflicts with Packages.Version -} )

-- Collections and maps
import VarSet
import VarEnv
import NameSet
import NameEnv
import UniqSet
import UniqFM
-- Conflicts with UniqFM:
--import LazyUniqFM
import FiniteMap

-- Common utilities
import Util
79
import GHC.Serialized
80 81 82 83 84
import SrcLoc
import Outputable
import UniqSupply
import Unique           ( Unique, Uniquable(..) )
import FastString