packages feed

ghcide 2.2.0.0 → 2.3.0.0

raw patch · 32 files changed

+187/−902 lines, 32 filesdep −aeson-prettydep ~ghcdep ~hls-graphdep ~hls-plugin-apiPVP ok

version bump matches the API change (PVP)

Dependencies removed: aeson-pretty

Dependency ranges changed: ghc, hls-graph, hls-plugin-api

API changes (from Hackage documentation)

- Development.IDE.GHC.Compat: supportsHieFiles :: Bool
- Development.IDE.GHC.Compat.Core: InferredSpec :: Specificity
- Development.IDE.GHC.Compat.Core: InvisArg :: AnonArgFlag
- Development.IDE.GHC.Compat.Core: Invisible :: Specificity -> ArgFlag
- Development.IDE.GHC.Compat.Core: NonDetUniqFM :: UniqFM key ele -> NonDetUniqFM key ele
- Development.IDE.GHC.Compat.Core: Required :: ArgFlag
- Development.IDE.GHC.Compat.Core: SpecifiedSpec :: Specificity
- Development.IDE.GHC.Compat.Core: TCvSubst :: InScopeSet -> TvSubstEnv -> CvSubstEnv -> TCvSubst
- Development.IDE.GHC.Compat.Core: TyCoFolder :: (Type -> Maybe Type) -> (env -> TyVar -> a) -> (env -> CoVar -> a) -> (env -> CoercionHole -> a) -> (env -> TyCoVar -> ArgFlag -> env) -> TyCoFolder env a
- Development.IDE.GHC.Compat.Core: TyCoMapper :: (env -> TyVar -> m Type) -> (env -> CoVar -> m Coercion) -> (env -> CoercionHole -> m Coercion) -> (env -> TyCoVar -> ArgFlag -> m (env, TyCoVar)) -> (TyCon -> m TyCon) -> TyCoMapper env (m :: Type -> Type)
- Development.IDE.GHC.Compat.Core: VisArg :: AnonArgFlag
- Development.IDE.GHC.Compat.Core: [getNonDet] :: NonDetUniqFM key ele -> UniqFM key ele
- Development.IDE.GHC.Compat.Core: [tcf_covar] :: TyCoFolder env a -> env -> CoVar -> a
- Development.IDE.GHC.Compat.Core: [tcf_hole] :: TyCoFolder env a -> env -> CoercionHole -> a
- Development.IDE.GHC.Compat.Core: [tcf_tycobinder] :: TyCoFolder env a -> env -> TyCoVar -> ArgFlag -> env
- Development.IDE.GHC.Compat.Core: [tcf_tyvar] :: TyCoFolder env a -> env -> TyVar -> a
- Development.IDE.GHC.Compat.Core: [tcf_view] :: TyCoFolder env a -> Type -> Maybe Type
- Development.IDE.GHC.Compat.Core: [tcm_covar] :: TyCoMapper env (m :: Type -> Type) -> env -> CoVar -> m Coercion
- Development.IDE.GHC.Compat.Core: [tcm_hole] :: TyCoMapper env (m :: Type -> Type) -> env -> CoercionHole -> m Coercion
- Development.IDE.GHC.Compat.Core: [tcm_tycobinder] :: TyCoMapper env (m :: Type -> Type) -> env -> TyCoVar -> ArgFlag -> m (env, TyCoVar)
- Development.IDE.GHC.Compat.Core: [tcm_tycon] :: TyCoMapper env (m :: Type -> Type) -> TyCon -> m TyCon
- Development.IDE.GHC.Compat.Core: [tcm_tyvar] :: TyCoMapper env (m :: Type -> Type) -> env -> TyVar -> m Type
- Development.IDE.GHC.Compat.Core: addListToUFM :: Uniquable key => UniqFM key elt -> [(key, elt)] -> UniqFM key elt
- Development.IDE.GHC.Compat.Core: addListToUFM_C :: Uniquable key => (elt -> elt -> elt) -> UniqFM key elt -> [(key, elt)] -> UniqFM key elt
- Development.IDE.GHC.Compat.Core: addListToUFM_Directly :: UniqFM key elt -> [(Unique, elt)] -> UniqFM key elt
- Development.IDE.GHC.Compat.Core: addToUFM :: Uniquable key => UniqFM key elt -> key -> elt -> UniqFM key elt
- Development.IDE.GHC.Compat.Core: addToUFM_Acc :: Uniquable key => (elt -> elts -> elts) -> (elt -> elts) -> UniqFM key elts -> key -> elt -> UniqFM key elts
- Development.IDE.GHC.Compat.Core: addToUFM_C :: Uniquable key => (elt -> elt -> elt) -> UniqFM key elt -> key -> elt -> UniqFM key elt
- Development.IDE.GHC.Compat.Core: addToUFM_Directly :: UniqFM key elt -> Unique -> elt -> UniqFM key elt
- Development.IDE.GHC.Compat.Core: adjustUFM :: Uniquable key => (elt -> elt) -> UniqFM key elt -> key -> UniqFM key elt
- Development.IDE.GHC.Compat.Core: adjustUFM_Directly :: (elt -> elt) -> UniqFM key elt -> Unique -> UniqFM key elt
- Development.IDE.GHC.Compat.Core: allUFM :: (elt -> Bool) -> UniqFM key elt -> Bool
- Development.IDE.GHC.Compat.Core: alterUFM :: Uniquable key => (Maybe elt -> Maybe elt) -> UniqFM key elt -> key -> UniqFM key elt
- Development.IDE.GHC.Compat.Core: anyFreeVarsOfType :: (TyCoVar -> Bool) -> Type -> Bool
- Development.IDE.GHC.Compat.Core: anyFreeVarsOfTypes :: (TyCoVar -> Bool) -> [Type] -> Bool
- Development.IDE.GHC.Compat.Core: anyUFM :: (elt -> Bool) -> UniqFM key elt -> Bool
- Development.IDE.GHC.Compat.Core: appTyArgFlags :: Type -> [Type] -> [ArgFlag]
- Development.IDE.GHC.Compat.Core: applyTysX :: [TyVar] -> Type -> [Type] -> Type
- Development.IDE.GHC.Compat.Core: binderArgFlag :: VarBndr tv argf -> argf
- Development.IDE.GHC.Compat.Core: binderRelevantType_maybe :: TyCoBinder -> Maybe Type
- Development.IDE.GHC.Compat.Core: binderType :: VarBndr TyCoVar argf -> Type
- Development.IDE.GHC.Compat.Core: binderVar :: VarBndr tv argf -> tv
- Development.IDE.GHC.Compat.Core: binderVars :: [VarBndr tv argf] -> [tv]
- Development.IDE.GHC.Compat.Core: buildSynTyCon :: Name -> [KnotTied TyConBinder] -> Kind -> [Role] -> KnotTied Type -> TyCon
- Development.IDE.GHC.Compat.Core: classifiesTypeWithValues :: Kind -> Bool
- Development.IDE.GHC.Compat.Core: cloneTyVarBndr :: TCvSubst -> TyVar -> Unique -> (TCvSubst, TyVar)
- Development.IDE.GHC.Compat.Core: cloneTyVarBndrs :: TCvSubst -> [TyVar] -> UniqSupply -> (TCvSubst, [TyVar])
- Development.IDE.GHC.Compat.Core: closeOverKinds :: TyCoVarSet -> TyCoVarSet
- Development.IDE.GHC.Compat.Core: closeOverKindsDSet :: DTyVarSet -> DTyVarSet
- Development.IDE.GHC.Compat.Core: closeOverKindsList :: [TyVar] -> [TyVar]
- Development.IDE.GHC.Compat.Core: coAxNthLHS :: forall (br :: BranchFlag). CoAxiom br -> Int -> Type
- Development.IDE.GHC.Compat.Core: coVarsOfType :: Type -> CoVarSet
- Development.IDE.GHC.Compat.Core: coVarsOfTypes :: [Type] -> CoVarSet
- Development.IDE.GHC.Compat.Core: composeTCvSubst :: TCvSubst -> TCvSubst -> TCvSubst
- Development.IDE.GHC.Compat.Core: composeTCvSubstEnv :: InScopeSet -> (TvSubstEnv, CvSubstEnv) -> (TvSubstEnv, CvSubstEnv) -> (TvSubstEnv, CvSubstEnv)
- Development.IDE.GHC.Compat.Core: coreView :: Type -> Maybe Type
- Development.IDE.GHC.Compat.Core: data AnonArgFlag
- Development.IDE.GHC.Compat.Core: data ArgFlag
- Development.IDE.GHC.Compat.Core: data Scaled a
- Development.IDE.GHC.Compat.Core: data Specificity
- Development.IDE.GHC.Compat.Core: data TCvSubst
- Development.IDE.GHC.Compat.Core: data TyCoBinder
- Development.IDE.GHC.Compat.Core: data TyCoFolder env a
- Development.IDE.GHC.Compat.Core: data TyCoMapper env (m :: Type -> Type)
- Development.IDE.GHC.Compat.Core: delFromUFM :: Uniquable key => UniqFM key elt -> key -> UniqFM key elt
- Development.IDE.GHC.Compat.Core: delFromUFM_Directly :: UniqFM key elt -> Unique -> UniqFM key elt
- Development.IDE.GHC.Compat.Core: delListFromUFM :: Uniquable key => UniqFM key elt -> [key] -> UniqFM key elt
- Development.IDE.GHC.Compat.Core: delListFromUFM_Directly :: UniqFM key elt -> [Unique] -> UniqFM key elt
- Development.IDE.GHC.Compat.Core: disjointUFM :: UniqFM key elt1 -> UniqFM key elt2 -> Bool
- Development.IDE.GHC.Compat.Core: dropForAlls :: Type -> Type
- Development.IDE.GHC.Compat.Core: dropRuntimeRepArgs :: [Type] -> [Type]
- Development.IDE.GHC.Compat.Core: elemUFM :: Uniquable key => key -> UniqFM key elt -> Bool
- Development.IDE.GHC.Compat.Core: elemUFM_Directly :: Unique -> UniqFM key elt -> Bool
- Development.IDE.GHC.Compat.Core: eltsUFM :: UniqFM key elt -> [elt]
- Development.IDE.GHC.Compat.Core: emptyTCvSubst :: TCvSubst
- Development.IDE.GHC.Compat.Core: emptyTvSubstEnv :: TvSubstEnv
- Development.IDE.GHC.Compat.Core: emptyUFM :: UniqFM key elt
- Development.IDE.GHC.Compat.Core: eqType :: Type -> Type -> Bool
- Development.IDE.GHC.Compat.Core: eqTypeX :: RnEnv2 -> Type -> Type -> Bool
- Development.IDE.GHC.Compat.Core: eqTypes :: [Type] -> [Type] -> Bool
- Development.IDE.GHC.Compat.Core: eqVarBndrs :: RnEnv2 -> [Var] -> [Var] -> Maybe RnEnv2
- Development.IDE.GHC.Compat.Core: equalKeysUFM :: UniqFM key a -> UniqFM key b -> Bool
- Development.IDE.GHC.Compat.Core: expandTypeSynonyms :: Type -> Type
- Development.IDE.GHC.Compat.Core: extendCvSubst :: TCvSubst -> CoVar -> Coercion -> TCvSubst
- Development.IDE.GHC.Compat.Core: extendTCvInScope :: TCvSubst -> Var -> TCvSubst
- Development.IDE.GHC.Compat.Core: extendTCvInScopeList :: TCvSubst -> [Var] -> TCvSubst
- Development.IDE.GHC.Compat.Core: extendTCvInScopeSet :: TCvSubst -> VarSet -> TCvSubst
- Development.IDE.GHC.Compat.Core: extendTCvSubst :: TCvSubst -> TyCoVar -> Type -> TCvSubst
- Development.IDE.GHC.Compat.Core: extendTCvSubstList :: TCvSubst -> [Var] -> [Type] -> TCvSubst
- Development.IDE.GHC.Compat.Core: extendTCvSubstWithClone :: TCvSubst -> TyCoVar -> TyCoVar -> TCvSubst
- Development.IDE.GHC.Compat.Core: extendTvSubst :: TCvSubst -> TyVar -> Type -> TCvSubst
- Development.IDE.GHC.Compat.Core: extendTvSubstAndInScope :: TCvSubst -> TyVar -> Type -> TCvSubst
- Development.IDE.GHC.Compat.Core: extendTvSubstBinderAndInScope :: TCvSubst -> TyCoBinder -> Type -> TCvSubst
- Development.IDE.GHC.Compat.Core: extendTvSubstList :: TCvSubst -> [Var] -> [Type] -> TCvSubst
- Development.IDE.GHC.Compat.Core: extendTvSubstWithClone :: TCvSubst -> TyVar -> TyVar -> TCvSubst
- Development.IDE.GHC.Compat.Core: filterOutInferredTypes :: TyCon -> [Type] -> [Type]
- Development.IDE.GHC.Compat.Core: filterOutInvisibleTypes :: TyCon -> [Type] -> [Type]
- Development.IDE.GHC.Compat.Core: filterUFM :: (elt -> Bool) -> UniqFM key elt -> UniqFM key elt
- Development.IDE.GHC.Compat.Core: filterUFM_Directly :: (Unique -> elt -> Bool) -> UniqFM key elt -> UniqFM key elt
- Development.IDE.GHC.Compat.Core: foldTyCo :: Monoid a => TyCoFolder env a -> env -> (Type -> a, [Type] -> a, Coercion -> a, [Coercion] -> a)
- Development.IDE.GHC.Compat.Core: foldUFM :: (elt -> a -> a) -> a -> UniqFM key elt -> a
- Development.IDE.GHC.Compat.Core: funArgTy :: Type -> Type
- Development.IDE.GHC.Compat.Core: funResultTy :: Type -> Type
- Development.IDE.GHC.Compat.Core: funTyCon :: TyCon
- Development.IDE.GHC.Compat.Core: getCastedTyVar_maybe :: Type -> Maybe (TyVar, CoercionN)
- Development.IDE.GHC.Compat.Core: getRuntimeRep :: HasDebugCallStack => Type -> Type
- Development.IDE.GHC.Compat.Core: getRuntimeRep_maybe :: HasDebugCallStack => Type -> Maybe Type
- Development.IDE.GHC.Compat.Core: getTCvInScope :: TCvSubst -> InScopeSet
- Development.IDE.GHC.Compat.Core: getTCvSubstRangeFVs :: TCvSubst -> VarSet
- Development.IDE.GHC.Compat.Core: getTvSubstEnv :: TCvSubst -> TvSubstEnv
- Development.IDE.GHC.Compat.Core: getTyVar :: String -> Type -> TyVar
- Development.IDE.GHC.Compat.Core: getTyVar_maybe :: Type -> Maybe TyVar
- Development.IDE.GHC.Compat.Core: infixr 3 `mkFunTy`
- Development.IDE.GHC.Compat.Core: initDynLinker :: HscEnv -> IO ()
- Development.IDE.GHC.Compat.Core: intersectUFM :: UniqFM key elt1 -> UniqFM key elt2 -> UniqFM key elt1
- Development.IDE.GHC.Compat.Core: intersectUFM_C :: (elt1 -> elt2 -> elt3) -> UniqFM key elt1 -> UniqFM key elt2 -> UniqFM key elt3
- Development.IDE.GHC.Compat.Core: invisibleTyBndrCount :: Type -> Int
- Development.IDE.GHC.Compat.Core: irrelevantMult :: Scaled a -> a
- Development.IDE.GHC.Compat.Core: isAlgType :: Type -> Bool
- Development.IDE.GHC.Compat.Core: isAnonTyCoBinder :: TyCoBinder -> Bool
- Development.IDE.GHC.Compat.Core: isAtomicTy :: Type -> Bool
- Development.IDE.GHC.Compat.Core: isBoxedRuntimeRep :: Type -> Bool
- Development.IDE.GHC.Compat.Core: isBoxedType :: Type -> Bool
- Development.IDE.GHC.Compat.Core: isBoxedTypeKind :: Kind -> Bool
- Development.IDE.GHC.Compat.Core: isCharLitTy :: Type -> Maybe Char
- Development.IDE.GHC.Compat.Core: isCoVarType :: Type -> Bool
- Development.IDE.GHC.Compat.Core: isCoercionTy :: Type -> Bool
- Development.IDE.GHC.Compat.Core: isCoercionTy_maybe :: Type -> Maybe Coercion
- Development.IDE.GHC.Compat.Core: isConstraintKindCon :: TyCon -> Bool
- Development.IDE.GHC.Compat.Core: isDataFamilyAppType :: Type -> Bool
- Development.IDE.GHC.Compat.Core: isEmptyTCvSubst :: TCvSubst -> Bool
- Development.IDE.GHC.Compat.Core: isFamFreeTy :: Type -> Bool
- Development.IDE.GHC.Compat.Core: isForAllTy :: Type -> Bool
- Development.IDE.GHC.Compat.Core: isForAllTy_co :: Type -> Bool
- Development.IDE.GHC.Compat.Core: isForAllTy_ty :: Type -> Bool
- Development.IDE.GHC.Compat.Core: isFunTy :: Type -> Bool
- Development.IDE.GHC.Compat.Core: isInScope :: Var -> TCvSubst -> Bool
- Development.IDE.GHC.Compat.Core: isInvisibleArgFlag :: ArgFlag -> Bool
- Development.IDE.GHC.Compat.Core: isInvisibleBinder :: TyCoBinder -> Bool
- Development.IDE.GHC.Compat.Core: isKindLevPoly :: Kind -> Bool
- Development.IDE.GHC.Compat.Core: isLevityTy :: Type -> Bool
- Development.IDE.GHC.Compat.Core: isLevityVar :: TyVar -> Bool
- Development.IDE.GHC.Compat.Core: isLiftedLevity :: Type -> Bool
- Development.IDE.GHC.Compat.Core: isLiftedRuntimeRep :: Type -> Bool
- Development.IDE.GHC.Compat.Core: isLiftedTypeKind :: Kind -> Bool
- Development.IDE.GHC.Compat.Core: isLiftedType_maybe :: HasDebugCallStack => Type -> Maybe Bool
- Development.IDE.GHC.Compat.Core: isLinearType :: Type -> Bool
- Development.IDE.GHC.Compat.Core: isLitTy :: Type -> Maybe TyLit
- Development.IDE.GHC.Compat.Core: isManyDataConTy :: Mult -> Bool
- Development.IDE.GHC.Compat.Core: isMultiplicityTy :: Type -> Bool
- Development.IDE.GHC.Compat.Core: isMultiplicityVar :: TyVar -> Bool
- Development.IDE.GHC.Compat.Core: isNamedBinder :: TyCoBinder -> Bool
- Development.IDE.GHC.Compat.Core: isNullUFM :: UniqFM key elt -> Bool
- Development.IDE.GHC.Compat.Core: isNumLitTy :: Type -> Maybe Integer
- Development.IDE.GHC.Compat.Core: isOneDataConTy :: Mult -> Bool
- Development.IDE.GHC.Compat.Core: isPiTy :: Type -> Bool
- Development.IDE.GHC.Compat.Core: isPredTy :: HasDebugCallStack => Type -> Bool
- Development.IDE.GHC.Compat.Core: isPrimitiveType :: Type -> Bool
- Development.IDE.GHC.Compat.Core: isRuntimeRepKindedTy :: Type -> Bool
- Development.IDE.GHC.Compat.Core: isRuntimeRepTy :: Type -> Bool
- Development.IDE.GHC.Compat.Core: isRuntimeRepVar :: TyVar -> Bool
- Development.IDE.GHC.Compat.Core: isStrLitTy :: Type -> Maybe FastString
- Development.IDE.GHC.Compat.Core: isStrictType :: HasDebugCallStack => Type -> Bool
- Development.IDE.GHC.Compat.Core: isTauTy :: Type -> Bool
- Development.IDE.GHC.Compat.Core: isTyVar :: Var -> Bool
- Development.IDE.GHC.Compat.Core: isTyVarTy :: Type -> Bool
- Development.IDE.GHC.Compat.Core: isTypeLevPoly :: Type -> Bool
- Development.IDE.GHC.Compat.Core: isUnboxedSumType :: Type -> Bool
- Development.IDE.GHC.Compat.Core: isUnboxedTupleType :: Type -> Bool
- Development.IDE.GHC.Compat.Core: isUnliftedLevity :: Type -> Bool
- Development.IDE.GHC.Compat.Core: isUnliftedRuntimeRep :: Type -> Bool
- Development.IDE.GHC.Compat.Core: isUnliftedType :: HasDebugCallStack => Type -> Bool
- Development.IDE.GHC.Compat.Core: isUnliftedTypeKind :: Kind -> Bool
- Development.IDE.GHC.Compat.Core: isValidJoinPointType :: JoinArity -> Type -> Bool
- Development.IDE.GHC.Compat.Core: isVisibleArgFlag :: ArgFlag -> Bool
- Development.IDE.GHC.Compat.Core: isVisibleBinder :: TyCoBinder -> Bool
- Development.IDE.GHC.Compat.Core: kindRep :: HasDebugCallStack => Kind -> Type
- Development.IDE.GHC.Compat.Core: kindRep_maybe :: HasDebugCallStack => Kind -> Maybe Type
- Development.IDE.GHC.Compat.Core: liftedTypeKind :: Kind
- Development.IDE.GHC.Compat.Core: linear :: a -> Scaled a
- Development.IDE.GHC.Compat.Core: listToIdentityUFM :: Uniquable key => [key] -> UniqFM key key
- Development.IDE.GHC.Compat.Core: listToUFM :: Uniquable key => [(key, elt)] -> UniqFM key elt
- Development.IDE.GHC.Compat.Core: listToUFM_C :: Uniquable key => (elt -> elt -> elt) -> [(key, elt)] -> UniqFM key elt
- Development.IDE.GHC.Compat.Core: listToUFM_Directly :: [(Unique, elt)] -> UniqFM key elt
- Development.IDE.GHC.Compat.Core: lookupTyVar :: TCvSubst -> TyVar -> Maybe Type
- Development.IDE.GHC.Compat.Core: lookupUFM :: Uniquable key => UniqFM key elt -> key -> Maybe elt
- Development.IDE.GHC.Compat.Core: lookupUFM_Directly :: UniqFM key elt -> Unique -> Maybe elt
- Development.IDE.GHC.Compat.Core: lookupWithDefaultUFM :: Uniquable key => UniqFM key elt -> elt -> key -> elt
- Development.IDE.GHC.Compat.Core: lookupWithDefaultUFM_Directly :: UniqFM key elt -> elt -> Unique -> elt
- Development.IDE.GHC.Compat.Core: mapMaybeUFM :: (elt1 -> Maybe elt2) -> UniqFM key elt1 -> UniqFM key elt2
- Development.IDE.GHC.Compat.Core: mapTyCo :: Monad m => TyCoMapper () m -> (Type -> m Type, [Type] -> m [Type], Coercion -> m Coercion, [Coercion] -> m [Coercion])
- Development.IDE.GHC.Compat.Core: mapTyCoX :: Monad m => TyCoMapper env m -> (env -> Type -> m Type, env -> [Type] -> m [Type], env -> Coercion -> m Coercion, env -> [Coercion] -> m [Coercion])
- Development.IDE.GHC.Compat.Core: mapUFM :: (elt1 -> elt2) -> UniqFM key elt1 -> UniqFM key elt2
- Development.IDE.GHC.Compat.Core: mapUFM_Directly :: (Unique -> elt1 -> elt2) -> UniqFM key elt1 -> UniqFM key elt2
- Development.IDE.GHC.Compat.Core: mergeUFM :: (elta -> eltb -> Maybe eltc) -> (UniqFM key elta -> UniqFM key eltc) -> (UniqFM key eltb -> UniqFM key eltc) -> UniqFM key elta -> UniqFM key eltb -> UniqFM key eltc
- Development.IDE.GHC.Compat.Core: mightBeUnliftedType :: Type -> Bool
- Development.IDE.GHC.Compat.Core: minusUFM :: UniqFM key elt1 -> UniqFM key elt2 -> UniqFM key elt1
- Development.IDE.GHC.Compat.Core: mkAnonBinder :: AnonArgFlag -> Scaled Type -> TyCoBinder
- Development.IDE.GHC.Compat.Core: mkAppTy :: Type -> Type -> Type
- Development.IDE.GHC.Compat.Core: mkAppTys :: Type -> [Type] -> Type
- Development.IDE.GHC.Compat.Core: mkCastTy :: Type -> Coercion -> Type
- Development.IDE.GHC.Compat.Core: mkCharLitTy :: Char -> Type
- Development.IDE.GHC.Compat.Core: mkCoercionTy :: Coercion -> Type
- Development.IDE.GHC.Compat.Core: mkEmptyTCvSubst :: InScopeSet -> TCvSubst
- Development.IDE.GHC.Compat.Core: mkFamilyTyConApp :: TyCon -> [Type] -> Type
- Development.IDE.GHC.Compat.Core: mkForAllTy :: TyCoVar -> ArgFlag -> Type -> Type
- Development.IDE.GHC.Compat.Core: mkForAllTys :: [TyCoVarBinder] -> Type -> Type
- Development.IDE.GHC.Compat.Core: mkFunTy :: AnonArgFlag -> Mult -> Type -> Type -> Type
- Development.IDE.GHC.Compat.Core: mkInfForAllTy :: TyVar -> Type -> Type
- Development.IDE.GHC.Compat.Core: mkInfForAllTys :: [TyVar] -> Type -> Type
- Development.IDE.GHC.Compat.Core: mkInvisForAllTys :: [InvisTVBinder] -> Type -> Type
- Development.IDE.GHC.Compat.Core: mkInvisFunTy :: Mult -> Type -> Type -> Type
- Development.IDE.GHC.Compat.Core: mkInvisFunTyMany :: Type -> Type -> Type
- Development.IDE.GHC.Compat.Core: mkInvisFunTysMany :: [Type] -> Type -> Type
- Development.IDE.GHC.Compat.Core: mkNumLitTy :: Integer -> Type
- Development.IDE.GHC.Compat.Core: mkPiTy :: TyCoBinder -> Type -> Type
- Development.IDE.GHC.Compat.Core: mkPiTys :: [TyCoBinder] -> Type -> Type
- Development.IDE.GHC.Compat.Core: mkScaled :: Mult -> a -> Scaled a
- Development.IDE.GHC.Compat.Core: mkSpecForAllTy :: TyVar -> Type -> Type
- Development.IDE.GHC.Compat.Core: mkSpecForAllTys :: [TyVar] -> Type -> Type
- Development.IDE.GHC.Compat.Core: mkStrLitTy :: FastString -> Type
- Development.IDE.GHC.Compat.Core: mkTCvSubst :: InScopeSet -> (TvSubstEnv, CvSubstEnv) -> TCvSubst
- Development.IDE.GHC.Compat.Core: mkTvSubstPrs :: [(TyVar, Type)] -> TCvSubst
- Development.IDE.GHC.Compat.Core: mkTyCoInvForAllTy :: TyCoVar -> Type -> Type
- Development.IDE.GHC.Compat.Core: mkTyCoInvForAllTys :: [TyCoVar] -> Type -> Type
- Development.IDE.GHC.Compat.Core: mkTyCoVarBinder :: vis -> TyCoVar -> VarBndr TyCoVar vis
- Development.IDE.GHC.Compat.Core: mkTyCoVarBinders :: vis -> [TyCoVar] -> [VarBndr TyCoVar vis]
- Development.IDE.GHC.Compat.Core: mkTyConApp :: TyCon -> [Type] -> Type
- Development.IDE.GHC.Compat.Core: mkTyConBindersPreferAnon :: [TyVar] -> TyCoVarSet -> [TyConBinder]
- Development.IDE.GHC.Compat.Core: mkTyConTy :: TyCon -> Type
- Development.IDE.GHC.Compat.Core: mkTyVarBinder :: vis -> TyVar -> VarBndr TyVar vis
- Development.IDE.GHC.Compat.Core: mkTyVarBinders :: vis -> [TyVar] -> [VarBndr TyVar vis]
- Development.IDE.GHC.Compat.Core: mkTyVarTy :: TyVar -> Type
- Development.IDE.GHC.Compat.Core: mkTyVarTys :: [TyVar] -> [Type]
- Development.IDE.GHC.Compat.Core: mkVisForAllTys :: [TyVar] -> Type -> Type
- Development.IDE.GHC.Compat.Core: mkVisFunTy :: Mult -> Type -> Type -> Type
- Development.IDE.GHC.Compat.Core: mkVisFunTyMany :: Type -> Type -> Type
- Development.IDE.GHC.Compat.Core: mkVisFunTysMany :: [Type] -> Type -> Type
- Development.IDE.GHC.Compat.Core: newTyConInstRhs :: TyCon -> [Type] -> Type
- Development.IDE.GHC.Compat.Core: newtype NonDetUniqFM key ele
- Development.IDE.GHC.Compat.Core: noFreeVarsOfType :: Type -> Bool
- Development.IDE.GHC.Compat.Core: nonDetCmpTc :: TyCon -> TyCon -> Ordering
- Development.IDE.GHC.Compat.Core: nonDetCmpType :: Type -> Type -> Ordering
- Development.IDE.GHC.Compat.Core: nonDetCmpTypeX :: RnEnv2 -> Type -> Type -> Ordering
- Development.IDE.GHC.Compat.Core: nonDetCmpTypes :: [Type] -> [Type] -> Ordering
- Development.IDE.GHC.Compat.Core: nonDetCmpTypesX :: RnEnv2 -> [Type] -> [Type] -> Ordering
- Development.IDE.GHC.Compat.Core: nonDetEltsUFM :: UniqFM key elt -> [elt]
- Development.IDE.GHC.Compat.Core: nonDetKeysUFM :: UniqFM key elt -> [Unique]
- Development.IDE.GHC.Compat.Core: nonDetStrictFoldUFM :: (elt -> a -> a) -> a -> UniqFM key elt -> a
- Development.IDE.GHC.Compat.Core: nonDetStrictFoldUFM_Directly :: (Unique -> elt -> a -> a) -> a -> UniqFM key elt -> a
- Development.IDE.GHC.Compat.Core: nonDetUFMToList :: UniqFM key elt -> [(Unique, elt)]
- Development.IDE.GHC.Compat.Core: notElemTCvSubst :: Var -> TCvSubst -> Bool
- Development.IDE.GHC.Compat.Core: occCheckExpand :: [Var] -> Type -> Maybe Type
- Development.IDE.GHC.Compat.Core: partitionInvisibleTypes :: TyCon -> [Type] -> ([Type], [Type])
- Development.IDE.GHC.Compat.Core: partitionInvisibles :: [(a, ArgFlag)] -> ([a], [a])
- Development.IDE.GHC.Compat.Core: partitionUFM :: (elt -> Bool) -> UniqFM key elt -> (UniqFM key elt, UniqFM key elt)
- Development.IDE.GHC.Compat.Core: pattern Inferred :: ArgFlag
- Development.IDE.GHC.Compat.Core: pattern Many :: Mult
- Development.IDE.GHC.Compat.Core: pattern One :: Mult
- Development.IDE.GHC.Compat.Core: pattern Specified :: ArgFlag
- Development.IDE.GHC.Compat.Core: piResultTy :: HasDebugCallStack => Type -> Type -> Type
- Development.IDE.GHC.Compat.Core: piResultTys :: HasDebugCallStack => Type -> [Type] -> Type
- Development.IDE.GHC.Compat.Core: pickyIsLiftedTypeKind :: Kind -> Bool
- Development.IDE.GHC.Compat.Core: pluralUFM :: UniqFM key a -> SDoc
- Development.IDE.GHC.Compat.Core: plusMaybeUFM_C :: (elt -> elt -> Maybe elt) -> UniqFM key elt -> UniqFM key elt -> UniqFM key elt
- Development.IDE.GHC.Compat.Core: plusUFM :: UniqFM key elt -> UniqFM key elt -> UniqFM key elt
- Development.IDE.GHC.Compat.Core: plusUFMList :: [UniqFM key elt] -> UniqFM key elt
- Development.IDE.GHC.Compat.Core: plusUFM_C :: (elt -> elt -> elt) -> UniqFM key elt -> UniqFM key elt -> UniqFM key elt
- Development.IDE.GHC.Compat.Core: plusUFM_CD :: (elta -> eltb -> eltc) -> UniqFM key elta -> elta -> UniqFM key eltb -> eltb -> UniqFM key eltc
- Development.IDE.GHC.Compat.Core: plusUFM_CD2 :: (Maybe elta -> Maybe eltb -> eltc) -> UniqFM key elta -> UniqFM key eltb -> UniqFM key eltc
- Development.IDE.GHC.Compat.Core: pprUFM :: UniqFM key a -> ([a] -> SDoc) -> SDoc
- Development.IDE.GHC.Compat.Core: pprUFMWithKeys :: UniqFM key a -> ([(Unique, a)] -> SDoc) -> SDoc
- Development.IDE.GHC.Compat.Core: pprUniqFM :: (a -> SDoc) -> UniqFM key a -> SDoc
- Development.IDE.GHC.Compat.Core: pprUserTypeErrorTy :: Type -> SDoc
- Development.IDE.GHC.Compat.Core: repGetTyVar_maybe :: Type -> Maybe TyVar
- Development.IDE.GHC.Compat.Core: repSplitAppTy_maybe :: HasDebugCallStack => Type -> Maybe (Type, Type)
- Development.IDE.GHC.Compat.Core: repSplitAppTys :: HasDebugCallStack => Type -> (Type, [Type])
- Development.IDE.GHC.Compat.Core: repSplitTyConApp_maybe :: HasDebugCallStack => Type -> Maybe (TyCon, [Type])
- Development.IDE.GHC.Compat.Core: resultIsLevPoly :: Type -> Bool
- Development.IDE.GHC.Compat.Core: sameVis :: ArgFlag -> ArgFlag -> Bool
- Development.IDE.GHC.Compat.Core: scaledSet :: Scaled a -> b -> Scaled b
- Development.IDE.GHC.Compat.Core: scopedSort :: [TyCoVar] -> [TyCoVar]
- Development.IDE.GHC.Compat.Core: seqEltsUFM :: ([elt] -> ()) -> UniqFM key elt -> ()
- Development.IDE.GHC.Compat.Core: seqType :: Type -> ()
- Development.IDE.GHC.Compat.Core: seqTypes :: [Type] -> ()
- Development.IDE.GHC.Compat.Core: setTvSubstEnv :: TCvSubst -> TvSubstEnv -> TCvSubst
- Development.IDE.GHC.Compat.Core: sizeUFM :: UniqFM key elt -> Int
- Development.IDE.GHC.Compat.Core: splitAppTy :: Type -> (Type, Type)
- Development.IDE.GHC.Compat.Core: splitAppTy_maybe :: Type -> Maybe (Type, Type)
- Development.IDE.GHC.Compat.Core: splitAppTys :: Type -> (Type, [Type])
- Development.IDE.GHC.Compat.Core: splitCastTy_maybe :: Type -> Maybe (Type, Coercion)
- Development.IDE.GHC.Compat.Core: splitForAllCoVar_maybe :: Type -> Maybe (TyCoVar, Type)
- Development.IDE.GHC.Compat.Core: splitForAllInvisTVBinders :: Type -> ([InvisTVBinder], Type)
- Development.IDE.GHC.Compat.Core: splitForAllReqTVBinders :: Type -> ([ReqTVBinder], Type)
- Development.IDE.GHC.Compat.Core: splitForAllTyCoVar :: Type -> (TyCoVar, Type)
- Development.IDE.GHC.Compat.Core: splitForAllTyCoVarBinders :: Type -> ([TyCoVarBinder], Type)
- Development.IDE.GHC.Compat.Core: splitForAllTyCoVar_maybe :: Type -> Maybe (TyCoVar, Type)
- Development.IDE.GHC.Compat.Core: splitForAllTyCoVars :: Type -> ([TyCoVar], Type)
- Development.IDE.GHC.Compat.Core: splitForAllTyVar_maybe :: Type -> Maybe (TyCoVar, Type)
- Development.IDE.GHC.Compat.Core: splitFunTy :: Type -> (Mult, Type, Type)
- Development.IDE.GHC.Compat.Core: splitFunTy_maybe :: Type -> Maybe (Mult, Type, Type)
- Development.IDE.GHC.Compat.Core: splitFunTys :: Type -> ([Scaled Type], Type)
- Development.IDE.GHC.Compat.Core: splitInvisPiTys :: Type -> ([TyCoBinder], Type)
- Development.IDE.GHC.Compat.Core: splitInvisPiTysN :: Int -> Type -> ([TyCoBinder], Type)
- Development.IDE.GHC.Compat.Core: splitListTyConApp_maybe :: Type -> Maybe Type
- Development.IDE.GHC.Compat.Core: splitPiTy :: Type -> (TyCoBinder, Type)
- Development.IDE.GHC.Compat.Core: splitPiTy_maybe :: Type -> Maybe (TyCoBinder, Type)
- Development.IDE.GHC.Compat.Core: splitPiTys :: Type -> ([TyCoBinder], Type)
- Development.IDE.GHC.Compat.Core: splitTyConApp :: Type -> (TyCon, [Type])
- Development.IDE.GHC.Compat.Core: splitTyConApp_maybe :: HasDebugCallStack => Type -> Maybe (TyCon, [Type])
- Development.IDE.GHC.Compat.Core: splitVisVarsOfType :: Type -> Pair TyCoVarSet
- Development.IDE.GHC.Compat.Core: splitVisVarsOfTypes :: [Type] -> Pair TyCoVarSet
- Development.IDE.GHC.Compat.Core: stripCoercionTy :: Type -> Coercion
- Development.IDE.GHC.Compat.Core: substCoUnchecked :: TCvSubst -> Coercion -> Coercion
- Development.IDE.GHC.Compat.Core: substCoWithUnchecked :: [TyVar] -> [Type] -> Coercion -> Coercion
- Development.IDE.GHC.Compat.Core: substScaledTy :: HasCallStack => TCvSubst -> Scaled Type -> Scaled Type
- Development.IDE.GHC.Compat.Core: substScaledTyUnchecked :: HasCallStack => TCvSubst -> Scaled Type -> Scaled Type
- Development.IDE.GHC.Compat.Core: substScaledTys :: HasCallStack => TCvSubst -> [Scaled Type] -> [Scaled Type]
- Development.IDE.GHC.Compat.Core: substScaledTysUnchecked :: TCvSubst -> [Scaled Type] -> [Scaled Type]
- Development.IDE.GHC.Compat.Core: substTheta :: HasCallStack => TCvSubst -> ThetaType -> ThetaType
- Development.IDE.GHC.Compat.Core: substThetaUnchecked :: TCvSubst -> ThetaType -> ThetaType
- Development.IDE.GHC.Compat.Core: substTy :: HasCallStack => TCvSubst -> Type -> Type
- Development.IDE.GHC.Compat.Core: substTyAddInScope :: TCvSubst -> Type -> Type
- Development.IDE.GHC.Compat.Core: substTyCoBndr :: TCvSubst -> TyCoBinder -> (TCvSubst, TyCoBinder)
- Development.IDE.GHC.Compat.Core: substTyUnchecked :: TCvSubst -> Type -> Type
- Development.IDE.GHC.Compat.Core: substTyVar :: TCvSubst -> TyVar -> Type
- Development.IDE.GHC.Compat.Core: substTyVarBndr :: HasCallStack => TCvSubst -> TyVar -> (TCvSubst, TyVar)
- Development.IDE.GHC.Compat.Core: substTyVarBndrs :: HasCallStack => TCvSubst -> [TyVar] -> (TCvSubst, [TyVar])
- Development.IDE.GHC.Compat.Core: substTyVars :: TCvSubst -> [TyVar] -> [Type]
- Development.IDE.GHC.Compat.Core: substTyWith :: HasCallStack => [TyVar] -> [Type] -> Type -> Type
- Development.IDE.GHC.Compat.Core: substTyWithUnchecked :: [TyVar] -> [Type] -> Type -> Type
- Development.IDE.GHC.Compat.Core: substTys :: HasCallStack => TCvSubst -> [Type] -> [Type]
- Development.IDE.GHC.Compat.Core: substTysUnchecked :: TCvSubst -> [Type] -> [Type]
- Development.IDE.GHC.Compat.Core: substTysWith :: [TyVar] -> [Type] -> [Type] -> [Type]
- Development.IDE.GHC.Compat.Core: substVarBndr :: HasCallStack => TCvSubst -> TyCoVar -> (TCvSubst, TyCoVar)
- Development.IDE.GHC.Compat.Core: substVarBndrs :: HasCallStack => TCvSubst -> [TyCoVar] -> (TCvSubst, [TyCoVar])
- Development.IDE.GHC.Compat.Core: tYPE :: Type -> Type
- Development.IDE.GHC.Compat.Core: tcIsBoxedTypeKind :: Kind -> Bool
- Development.IDE.GHC.Compat.Core: tcIsConstraintKind :: Kind -> Bool
- Development.IDE.GHC.Compat.Core: tcIsLiftedTypeKind :: Kind -> Bool
- Development.IDE.GHC.Compat.Core: tcIsRuntimeTypeKind :: Kind -> Bool
- Development.IDE.GHC.Compat.Core: tcRepSplitAppTy_maybe :: Type -> Maybe (Type, Type)
- Development.IDE.GHC.Compat.Core: tcRepSplitTyConApp_maybe :: HasDebugCallStack => Type -> Maybe (TyCon, [Type])
- Development.IDE.GHC.Compat.Core: tcReturnsConstraintKind :: Kind -> Bool
- Development.IDE.GHC.Compat.Core: tcSplitTyConApp_maybe :: HasCallStack => Type -> Maybe (TyCon, [Type])
- Development.IDE.GHC.Compat.Core: tcTypeKind :: HasDebugCallStack => Type -> Kind
- Development.IDE.GHC.Compat.Core: tcView :: Type -> Maybe Type
- Development.IDE.GHC.Compat.Core: tidyFreeTyCoVars :: TidyEnv -> [TyCoVar] -> TidyEnv
- Development.IDE.GHC.Compat.Core: tidyKind :: TidyEnv -> Kind -> Kind
- Development.IDE.GHC.Compat.Core: tidyOpenKind :: TidyEnv -> Kind -> (TidyEnv, Kind)
- Development.IDE.GHC.Compat.Core: tidyOpenTyCoVar :: TidyEnv -> TyCoVar -> (TidyEnv, TyCoVar)
- Development.IDE.GHC.Compat.Core: tidyOpenTyCoVars :: TidyEnv -> [TyCoVar] -> (TidyEnv, [TyCoVar])
- Development.IDE.GHC.Compat.Core: tidyOpenType :: TidyEnv -> Type -> (TidyEnv, Type)
- Development.IDE.GHC.Compat.Core: tidyOpenTypes :: TidyEnv -> [Type] -> (TidyEnv, [Type])
- Development.IDE.GHC.Compat.Core: tidyTopType :: Type -> Type
- Development.IDE.GHC.Compat.Core: tidyTyCoVarBinder :: TidyEnv -> VarBndr TyCoVar vis -> (TidyEnv, VarBndr TyCoVar vis)
- Development.IDE.GHC.Compat.Core: tidyTyCoVarBinders :: TidyEnv -> [VarBndr TyCoVar vis] -> (TidyEnv, [VarBndr TyCoVar vis])
- Development.IDE.GHC.Compat.Core: tidyTyCoVarOcc :: TidyEnv -> TyCoVar -> TyCoVar
- Development.IDE.GHC.Compat.Core: tidyType :: TidyEnv -> Type -> Type
- Development.IDE.GHC.Compat.Core: tidyTypes :: TidyEnv -> [Type] -> [Type]
- Development.IDE.GHC.Compat.Core: tidyVarBndr :: TidyEnv -> TyCoVar -> (TidyEnv, TyCoVar)
- Development.IDE.GHC.Compat.Core: tidyVarBndrs :: TidyEnv -> [TyCoVar] -> (TidyEnv, [TyCoVar])
- Development.IDE.GHC.Compat.Core: tyBinderType :: TyBinder -> Type
- Development.IDE.GHC.Compat.Core: tyCoBinderType :: TyCoBinder -> Type
- Development.IDE.GHC.Compat.Core: tyCoBinderVar_maybe :: TyCoBinder -> Maybe TyCoVar
- Development.IDE.GHC.Compat.Core: tyCoFVsBndr :: TyCoVarBinder -> FV -> FV
- Development.IDE.GHC.Compat.Core: tyCoFVsOfType :: Type -> FV
- Development.IDE.GHC.Compat.Core: tyCoFVsVarBndr :: Var -> FV -> FV
- Development.IDE.GHC.Compat.Core: tyCoFVsVarBndrs :: [Var] -> FV -> FV
- Development.IDE.GHC.Compat.Core: tyCoVarsOfType :: Type -> TyCoVarSet
- Development.IDE.GHC.Compat.Core: tyCoVarsOfTypeDSet :: Type -> DTyCoVarSet
- Development.IDE.GHC.Compat.Core: tyCoVarsOfTypeWellScoped :: Type -> [TyVar]
- Development.IDE.GHC.Compat.Core: tyCoVarsOfTypes :: [Type] -> TyCoVarSet
- Development.IDE.GHC.Compat.Core: tyCoVarsOfTypesWellScoped :: [Type] -> [TyVar]
- Development.IDE.GHC.Compat.Core: tyConAppArgN :: Int -> Type -> Type
- Development.IDE.GHC.Compat.Core: tyConAppArgs :: Type -> [Type]
- Development.IDE.GHC.Compat.Core: tyConAppArgs_maybe :: Type -> Maybe [Type]
- Development.IDE.GHC.Compat.Core: tyConAppNeedsKindSig :: Bool -> TyCon -> Int -> Bool
- Development.IDE.GHC.Compat.Core: tyConAppTyCon :: Type -> TyCon
- Development.IDE.GHC.Compat.Core: tyConAppTyConPicky_maybe :: Type -> Maybe TyCon
- Development.IDE.GHC.Compat.Core: tyConAppTyCon_maybe :: Type -> Maybe TyCon
- Development.IDE.GHC.Compat.Core: tyConArgFlags :: TyCon -> [Type] -> [ArgFlag]
- Development.IDE.GHC.Compat.Core: tyConBindersTyCoBinders :: [TyConBinder] -> [TyCoBinder]
- Development.IDE.GHC.Compat.Core: tyConsOfType :: Type -> UniqSet TyCon
- Development.IDE.GHC.Compat.Core: tyVarKind :: TyVar -> Kind
- Development.IDE.GHC.Compat.Core: tyVarSpecToBinders :: [VarBndr a Specificity] -> [VarBndr a ArgFlag]
- Development.IDE.GHC.Compat.Core: tymult :: a -> Scaled a
- Development.IDE.GHC.Compat.Core: type Kind = Type
- Development.IDE.GHC.Compat.Core: type KindOrType = Type
- Development.IDE.GHC.Compat.Core: type KnotTied ty = ty
- Development.IDE.GHC.Compat.Core: type PredType = Type
- Development.IDE.GHC.Compat.Core: type ThetaType = [PredType]
- Development.IDE.GHC.Compat.Core: type TvSubstEnv = TyVarEnv Type
- Development.IDE.GHC.Compat.Core: type TyCoVar = Id
- Development.IDE.GHC.Compat.Core: type TyCoVarBinder = VarBndr TyCoVar ArgFlag
- Development.IDE.GHC.Compat.Core: type TyVar = Var
- Development.IDE.GHC.Compat.Core: type TyVarBinder = VarBndr TyVar ArgFlag
- Development.IDE.GHC.Compat.Core: type UniqFM = UniqFM
- Development.IDE.GHC.Compat.Core: typeKind :: HasDebugCallStack => Type -> Kind
- Development.IDE.GHC.Compat.Core: typeSize :: Type -> Int
- Development.IDE.GHC.Compat.Core: ufmToIntMap :: UniqFM key elt -> IntMap elt
- Development.IDE.GHC.Compat.Core: ufmToSet_Directly :: UniqFM key elt -> IntSet
- Development.IDE.GHC.Compat.Core: unionTCvSubst :: TCvSubst -> TCvSubst -> TCvSubst
- Development.IDE.GHC.Compat.Core: unitDirectlyUFM :: Unique -> elt -> UniqFM key elt
- Development.IDE.GHC.Compat.Core: unitUFM :: Uniquable key => key -> elt -> UniqFM key elt
- Development.IDE.GHC.Compat.Core: unliftedTypeKind :: Kind
- Development.IDE.GHC.Compat.Core: unrestricted :: a -> Scaled a
- Development.IDE.GHC.Compat.Core: unrestrictedFunTyCon :: TyCon
- Development.IDE.GHC.Compat.Core: unsafeCastUFMKey :: UniqFM key1 elt -> UniqFM key2 elt
- Development.IDE.GHC.Compat.Core: unsafeIntMapToUFM :: IntMap elt -> UniqFM key elt
- Development.IDE.GHC.Compat.Core: userTypeError_maybe :: Type -> Maybe Type
- Development.IDE.GHC.Compat.Core: zapTCvSubst :: TCvSubst -> TCvSubst
- Development.IDE.GHC.Compat.Core: zipCoEnv :: HasDebugCallStack => [CoVar] -> [Coercion] -> CvSubstEnv
- Development.IDE.GHC.Compat.Core: zipTCvSubst :: HasDebugCallStack => [TyCoVar] -> [Type] -> TCvSubst
- Development.IDE.GHC.Compat.Core: zipToUFM :: Uniquable key => [key] -> [elt] -> UniqFM key elt
- Development.IDE.GHC.Compat.Core: zipTvSubst :: HasDebugCallStack => [TyVar] -> [Type] -> TCvSubst
- Development.IDE.GHC.Compat.Core: zipTyEnv :: HasDebugCallStack => [TyVar] -> [Type] -> TvSubstEnv
- Development.IDE.GHC.Compat.Units: unitInfoId :: UnitInfo -> Unit
- Development.IDE.GHC.Orphans: instance Control.DeepSeq.NFData (Development.IDE.GHC.Compat.Core.UniqFM GHC.Types.Name.Name [GHC.Types.Name.Name])
- Development.IDE.Session: instance GHC.Show.Show Development.IDE.Session.MultiCradleErr
+ Development.IDE.GHC.Compat.Core: data UniqFM key ele
+ Development.IDE.GHC.Compat.Units: mkUnit :: UnitInfo -> Unit
+ Development.IDE.GHC.Orphans: instance Control.DeepSeq.NFData (GHC.Types.Unique.FM.UniqFM GHC.Types.Name.Name [GHC.Types.Name.Name])
+ Development.IDE.Session.Diagnostics: CradleErrorDetails :: [FilePath] -> CradleErrorDetails
+ Development.IDE.Session.Diagnostics: MultiCradleErr :: FilePath -> FilePath -> [(FilePath, String)] -> MultiCradleErr
+ Development.IDE.Session.Diagnostics: [cabalProjectFiles] :: CradleErrorDetails -> [FilePath]
+ Development.IDE.Session.Diagnostics: [mcFilePath] :: MultiCradleErr -> FilePath
+ Development.IDE.Session.Diagnostics: [mcPrefixes] :: MultiCradleErr -> [(FilePath, String)]
+ Development.IDE.Session.Diagnostics: [mcPwd] :: MultiCradleErr -> FilePath
+ Development.IDE.Session.Diagnostics: data CradleErrorDetails
+ Development.IDE.Session.Diagnostics: data MultiCradleErr
+ Development.IDE.Session.Diagnostics: instance Data.Aeson.Types.FromJSON.FromJSON Development.IDE.Session.Diagnostics.CradleErrorDetails
+ Development.IDE.Session.Diagnostics: instance Data.Aeson.Types.ToJSON.ToJSON Development.IDE.Session.Diagnostics.CradleErrorDetails
+ Development.IDE.Session.Diagnostics: instance GHC.Classes.Eq Development.IDE.Session.Diagnostics.CradleErrorDetails
+ Development.IDE.Session.Diagnostics: instance GHC.Classes.Ord Development.IDE.Session.Diagnostics.CradleErrorDetails
+ Development.IDE.Session.Diagnostics: instance GHC.Generics.Generic Development.IDE.Session.Diagnostics.CradleErrorDetails
+ Development.IDE.Session.Diagnostics: instance GHC.Read.Read Development.IDE.Session.Diagnostics.CradleErrorDetails
+ Development.IDE.Session.Diagnostics: instance GHC.Show.Show Development.IDE.Session.Diagnostics.CradleErrorDetails
+ Development.IDE.Session.Diagnostics: instance GHC.Show.Show Development.IDE.Session.Diagnostics.MultiCradleErr
+ Development.IDE.Session.Diagnostics: multiCradleErrMessage :: MultiCradleErr -> [String]
+ Development.IDE.Session.Diagnostics: parseMultiCradleErr :: [String] -> Maybe MultiCradleErr
+ Development.IDE.Session.Diagnostics: renderCradleError :: CradleError -> Cradle a -> NormalizedFilePath -> FileDiagnostic
+ Development.IDE.Session.Diagnostics: unknownModuleMessage :: String -> [String]
- Development.IDE.GHC.Compat.Units: moduleUnit :: Module -> Unit
+ Development.IDE.GHC.Compat.Units: moduleUnit :: GenModule unit -> unit
- Development.IDE.GHC.Compat.Units: unitDepends :: UnitInfo -> [UnitId]
+ Development.IDE.GHC.Compat.Units: unitDepends :: GenericUnitInfo compid srcpkgid srcpkgname uid modulename mod -> [uid]
- Development.IDE.GHC.Compat.Units: unitExposedModules :: UnitInfo -> [(ModuleName, Maybe Module)]
+ Development.IDE.GHC.Compat.Units: unitExposedModules :: GenericUnitInfo compid srcpkgid srcpkgname uid modulename mod -> [(modulename, Maybe mod)]
- Development.IDE.GHC.Compat.Units: unitPackageNameString :: UnitInfo -> String
+ Development.IDE.GHC.Compat.Units: unitPackageNameString :: GenUnitInfo u -> String
- Development.IDE.GHC.Compat.Units: unitPackageVersion :: UnitInfo -> Version
+ Development.IDE.GHC.Compat.Units: unitPackageVersion :: GenericUnitInfo compid srcpkgid srcpkgname uid modulename mod -> Version

Files

ghcide.cabal view
@@ -2,7 +2,7 @@ build-type:         Simple category:           Development name:               ghcide-version:            2.2.0.0+version:            2.3.0.0 license:            Apache-2.0 license-file:       LICENSE author:             Digital Asset and Ghcide contributors@@ -13,7 +13,7 @@     A library for building Haskell IDE's on top of the GHC API. homepage:           https://github.com/haskell/haskell-language-server/tree/master/ghcide#readme bug-reports:        https://github.com/haskell/haskell-language-server/issues-tested-with:        GHC == 8.10.7 || == 9.0.2 || == 9.2.5+tested-with:        GHC == 9.0.2 || == 9.2.5 extra-source-files: README.md CHANGELOG.md                     test/data/**/*.project                     test/data/**/*.cabal@@ -44,7 +44,6 @@     default-language:   Haskell2010     build-depends:         aeson,-        aeson-pretty,         array,         async,         base == 4.*,@@ -70,7 +69,7 @@         haddock-library >= 1.8 && < 1.12,         hashable,         hie-compat ^>= 0.3.0.0,-        hls-plugin-api == 2.2.0.0,+        hls-plugin-api == 2.3.0.0,         lens,         list-t,         hiedb == 0.4.3.*,@@ -86,7 +85,7 @@         row-types,         text-rope,         safe-exceptions,-        hls-graph == 2.2.0.0,+        hls-graph == 2.3.0.0,         sorted-list,         sqlite-simple,         stm,@@ -104,7 +103,7 @@         unliftio-core,         ghc-boot-th,         ghc-boot,-        ghc >= 8.10,+        ghc >= 9.0,         ghc-check >=0.5.0.8,         ghc-paths,         cryptohash-sha1 >=0.11.100 && <0.12,@@ -193,6 +192,7 @@         Development.IDE.LSP.Outline         Development.IDE.LSP.Server         Development.IDE.Session+        Development.IDE.Session.Diagnostics         Development.IDE.Spans.Common         Development.IDE.Spans.Documentation         Development.IDE.Spans.AtPoint@@ -228,6 +228,7 @@                 -Wall                 -Wincomplete-uni-patterns                 -Wno-unticked-promoted-constructors+                -Wunused-packages                 -fno-ignore-asserts      if flag(ghc-patched-unboxed-bytecode)@@ -254,9 +255,6 @@     if impl(ghc >= 9.2) && flag(pedantic)         ghc-options: -Wwarn=ambiguous-fields -    if impl(ghc >= 9)-        ghc-options: -Wunused-packages-     if flag(ekg)         build-depends:             ekg-wai,@@ -397,10 +395,8 @@           record-hasfield     if impl(ghc < 9.3)        build-depends:  ghc-typelits-knownnat-    if impl(ghc >= 9)-        ghc-options: -Wunused-packages     hs-source-dirs: test/cabal test/exe test/src-    ghc-options: -threaded -Wall -Wno-name-shadowing -O0 -Wno-unticked-promoted-constructors+    ghc-options: -threaded -Wall -Wno-name-shadowing -O0 -Wno-unticked-promoted-constructors -Wunused-packages     main-is: Main.hs     other-modules:         Development.IDE.Test.Runfiles
session-loader/Development/IDE/Session.hs view
@@ -34,14 +34,12 @@ import           Data.Bifunctor import qualified Data.ByteString.Base16               as B16 import qualified Data.ByteString.Char8                as B-import           Data.Char                            (isLower) import           Data.Default import           Data.Either.Extra import           Data.Function import           Data.Hashable                        hiding (hash) import qualified Data.HashMap.Strict                  as HM import           Data.List-import           Data.List.Extra                      (dropPrefix, split) import qualified Data.Map.Strict                      as Map import           Data.Maybe import           Data.Proxy@@ -69,7 +67,6 @@ import           Development.IDE.Types.Options import           GHC.Check import qualified HIE.Bios                             as HieBios-import qualified HIE.Bios.Cradle                      as HieBios import           HIE.Bios.Environment                 hiding (getCacheDir) import           HIE.Bios.Types                       hiding (Log) import qualified HIE.Bios.Types                       as HieBios@@ -103,6 +100,7 @@ import qualified Data.HashSet                         as Set import           Database.SQLite.Simple import           Development.IDE.Core.Tracing         (withTrace)+import           Development.IDE.Session.Diagnostics  (renderCradleError) import           Development.IDE.Types.Shake          (WithHieDb) import           HieDb.Create import           HieDb.Types@@ -685,7 +683,7 @@              Left err -> do                dep_info <- getDependencyInfo (maybeToList hieYaml)                let ncfp = toNormalizedFilePath' cfp-               let res = (map (renderCradleError cradle ncfp) err, Nothing)+               let res = (map (\err' -> renderCradleError err' cradle ncfp) err, Nothing)                void $ modifyVar' fileToFlags $                     Map.insertWith HM.union hieYaml (HM.singleton ncfp (res, dep_info))                void $ modifyVar' filesMap $ HM.insert ncfp hieYaml@@ -768,7 +766,6 @@ #endif emptyHscEnv nc libDir = do     env <- runGhc (Just libDir) getSession-    initDynLinker env     pure $ setNameCache nc (hscSetFlags ((hsc_dflags env){useUnicode = True }) env)  data TargetDetails = TargetDetails@@ -924,72 +921,6 @@           & maybe id setHiDir hiCacheDir           & maybe id setHieDir hieCacheDir           & maybe id setODir oCacheDir---renderCradleError :: Cradle a -> NormalizedFilePath -> CradleError -> FileDiagnostic-renderCradleError cradle nfp (CradleError _ _ec ms) =-  ideErrorWithSource (Just "cradle") (Just DiagnosticSeverity_Error) nfp $ T.unlines $ map T.pack userFriendlyMessage-  where--    userFriendlyMessage :: [String]-    userFriendlyMessage-      | HieBios.isCabalCradle cradle = fromMaybe ms fileMissingMessage-      | otherwise = ms--    fileMissingMessage :: Maybe [String]-    fileMissingMessage =-      multiCradleErrMessage <$> parseMultiCradleErr ms---- | Information included in Multi Cradle error messages-data MultiCradleErr = MultiCradleErr-  { mcPwd      :: FilePath-  , mcFilePath :: FilePath-  , mcPrefixes :: [(FilePath, String)]-  } deriving (Show)---- | Attempt to parse a multi-cradle message-parseMultiCradleErr :: [String] -> Maybe MultiCradleErr-parseMultiCradleErr ms = do-  _  <- lineAfter "Multi Cradle: "-  wd <- lineAfter "pwd: "-  fp <- lineAfter "filepath: "-  ps <- prefixes-  pure $ MultiCradleErr wd fp ps--  where-    lineAfter :: String -> Maybe String-    lineAfter pre = listToMaybe $ mapMaybe (stripPrefix pre) ms--    prefixes :: Maybe [(FilePath, String)]-    prefixes = do-      pure $ mapMaybe tuple ms--    tuple :: String -> Maybe (String, String)-    tuple line = do-      line' <- surround '(' line ')'-      [f, s] <- pure $ split (==',') line'-      pure (f, s)--    -- extracts the string surrounded by required characters-    surround :: Char -> String -> Char -> Maybe String-    surround start s end = do-      guard (listToMaybe s == Just start)-      guard (listToMaybe (reverse s) == Just end)-      pure $ drop 1 $ take (length s - 1) s--multiCradleErrMessage :: MultiCradleErr -> [String]-multiCradleErrMessage e =-    [ "Loading the module '" <> moduleFileName <> "' failed. It may not be listed in your .cabal file!"-    , "Perhaps you need to add `"<> moduleName <> "` to other-modules or exposed-modules."-    , "For more information, visit: https://cabal.readthedocs.io/en/3.4/developing-packages.html#modules-included-in-the-package"-    , ""-    ] <> map prefix (mcPrefixes e)-  where-    localFilePath f = dropWhile (==pathSeparator) $ dropPrefix (mcPwd e) f-    moduleFileName = localFilePath $ mcFilePath e-    moduleName = intercalate "." $ map dropExtension $ dropWhile isSourceFolder $ splitDirectories moduleFileName-    isSourceFolder p = all isLower $ take 1 p-    prefix (f, r) = f <> " - " <> r  -- See Note [Multi Cradle Dependency Info] type DependencyInfo = Map.Map FilePath (Maybe UTCTime)
+ session-loader/Development/IDE/Session/Diagnostics.hs view
@@ -0,0 +1,106 @@+{-# LANGUAGE DeriveAnyClass #-}+{-# LANGUAGE DeriveGeneric  #-}++module Development.IDE.Session.Diagnostics where+import           Control.Applicative+import           Control.Monad+import qualified Data.Aeson                        as Aeson+import           Data.List+import           Data.List.Extra                   (split)+import           Data.Maybe+import qualified Data.Text                         as T+import           Development.IDE.Types.Diagnostics+import           Development.IDE.Types.Location+import           GHC.Generics+import qualified HIE.Bios.Cradle                   as HieBios+import           HIE.Bios.Types                    hiding (Log)+import           System.FilePath++data CradleErrorDetails =+  CradleErrorDetails+    { cabalProjectFiles :: [FilePath]+    -- ^ files related to the cradle error+    -- i.e. .cabal, cabal.project, etc.+    } deriving (Show, Eq, Ord, Read, Generic, Aeson.ToJSON, Aeson.FromJSON)++{- | Takes a cradle error, the corresponding cradle and the file path where+  the cradle error occurred (of the file we attempted to load).+  Depicts the cradle error in a user-friendly way.+-}+renderCradleError :: CradleError -> Cradle a -> NormalizedFilePath -> FileDiagnostic+renderCradleError (CradleError deps _ec ms) cradle nfp+  | HieBios.isCabalCradle cradle =+      let (fp, showDiag, diag) = ideErrorWithSource (Just "cradle") (Just DiagnosticSeverity_Error) nfp $ T.unlines $ map T.pack userFriendlyMessage in+        (fp, showDiag, diag{_data_ = Just $ Aeson.toJSON CradleErrorDetails{cabalProjectFiles=absDeps}})+  | otherwise = ideErrorWithSource (Just "cradle") (Just DiagnosticSeverity_Error) nfp $ T.unlines $ map T.pack userFriendlyMessage+  where+    absDeps = fmap (cradleRootDir cradle </>) deps+    userFriendlyMessage :: [String]+    userFriendlyMessage+      | HieBios.isCabalCradle cradle = fromMaybe ms $ fileMissingMessage <|> mkUnknownModuleMessage+      | otherwise = ms++    mkUnknownModuleMessage :: Maybe [String]+    mkUnknownModuleMessage+      | any (isInfixOf "Failed extracting script block:") ms =+          Just $ unknownModuleMessage (fromNormalizedFilePath nfp)+      | otherwise = Nothing++    fileMissingMessage :: Maybe [String]+    fileMissingMessage =+      multiCradleErrMessage <$> parseMultiCradleErr ms++-- | Information included in Multi Cradle error messages+data MultiCradleErr = MultiCradleErr+  { mcPwd      :: FilePath+  , mcFilePath :: FilePath+  , mcPrefixes :: [(FilePath, String)]+  } deriving (Show)++-- | Attempt to parse a multi-cradle message+parseMultiCradleErr :: [String] -> Maybe MultiCradleErr+parseMultiCradleErr ms = do+  _  <- lineAfter "Multi Cradle: "+  wd <- lineAfter "pwd: "+  fp <- lineAfter "filepath: "+  ps <- prefixes+  pure $ MultiCradleErr wd fp ps++  where+    lineAfter :: String -> Maybe String+    lineAfter pre = listToMaybe $ mapMaybe (stripPrefix pre) ms++    prefixes :: Maybe [(FilePath, String)]+    prefixes = do+      pure $ mapMaybe tuple ms++    tuple :: String -> Maybe (String, String)+    tuple line = do+      line' <- surround '(' line ')'+      [f, s] <- pure $ split (==',') line'+      pure (f, s)++    -- extracts the string surrounded by required characters+    surround :: Char -> String -> Char -> Maybe String+    surround start s end = do+      guard (listToMaybe s == Just start)+      guard (listToMaybe (reverse s) == Just end)+      pure $ drop 1 $ take (length s - 1) s++multiCradleErrMessage :: MultiCradleErr -> [String]+multiCradleErrMessage e =+    unknownModuleMessage (mcFilePath e)+    <> [""]+    <> map prefix (mcPrefixes e)+  where+    prefix (f, r) = f <> " - " <> r++unknownModuleMessage :: String -> [String]+unknownModuleMessage moduleFileName =+  [ "Loading the module '" <> moduleFileName <> "' failed."+  , ""+  , "It may not be listed in your .cabal file!"+  , "Perhaps you need to add `"<> dropExtension (takeFileName moduleFileName) <> "` to other-modules or exposed-modules."+  , ""+  , "For more information, visit: https://cabal.readthedocs.io/en/3.4/developing-packages.html#modules-included-in-the-package"+  ]
src/Development/IDE/Core/Compile.hs view
@@ -108,16 +108,9 @@  -- See Note [Guidelines For Using CPP In GHCIDE Import Statements] -#if !MIN_VERSION_ghc(9,0,1)-import           HscTypes-import           TcSplice-#endif--#if MIN_VERSION_ghc(9,0,1) import           GHC.Tc.Gen.Splice-#endif -#if MIN_VERSION_ghc(9,0,1) && !MIN_VERSION_ghc(9,2,1)+#if !MIN_VERSION_ghc(9,2,1) import           GHC.Driver.Types #endif @@ -525,7 +518,6 @@         (guts, details) <- tidyProgram tidy_opts simplified_guts         pure (details, guts) -#if MIN_VERSION_ghc(9,0,1)   let !partial_iface = force $ mkPartialIface session #if MIN_VERSION_ghc(9,5,0)                                               (cg_binds guts)@@ -540,11 +532,6 @@ #if MIN_VERSION_ghc(9,4,2)                     Nothing #endif--#else-  let !partial_iface = force (mkPartialIface session details simplified_guts)-  final_iface' <- mkFullIface session partial_iface-#endif   let final_iface = final_iface' {mi_globals = Nothing, mi_usages = filterUsages (mi_usages final_iface')} -- See Note [Clearing mi_globals after generating an iface]    -- Write the core file now@@ -693,10 +680,8 @@                           session' = hscSetFlags newFlags session #if MIN_VERSION_ghc(9,4,2)                       (outputFilename, _mStub, _foreign_files, _cinfos, _stgcinfos) <- hscGenHardCode session' guts-#elif MIN_VERSION_ghc(9,0,1)-                      (outputFilename, _mStub, _foreign_files, _cinfos) <- hscGenHardCode session' guts #else-                      (outputFilename, _mStub, _foreign_files) <- hscGenHardCode session' guts+                      (outputFilename, _mStub, _foreign_files, _cinfos) <- hscGenHardCode session' guts #endif                                 (ms_location summary)                                 fp@@ -839,7 +824,6 @@     -- don't export an interface which allows for additional information to be added to hie files.     let fake_splice_binds = Util.listToBag (map (mkVarBind unitDataConId) (spliceExpressions $ tmrTopLevelSplices tcm))         real_binds = tcg_binds $ tmrTypechecked tcm-#if MIN_VERSION_ghc(9,0,1)         ts = tmrTypechecked tcm :: TcGblEnv         top_ev_binds = tcg_ev_binds ts :: Util.Bag EvBind         insts = tcg_insts ts :: [ClsInst]@@ -851,19 +835,14 @@       Just <$> #endif           GHC.enrichHie (fake_splice_binds `Util.unionBags` real_binds) (tmrRenamed tcm) top_ev_binds insts tcs-#else-    Just <$> GHC.enrichHie (fake_splice_binds `Util.unionBags` real_binds) (tmrRenamed tcm)-#endif   where     dflags = hsc_dflags hscEnv-#if MIN_VERSION_ghc(9,0,0)     run _ts = -- ts is only used in GHC 9.2 #if MIN_VERSION_ghc(9,2,0) && !MIN_VERSION_ghc(9,3,0)         fmap (join . snd) . liftIO . initDs hscEnv _ts #else         id #endif-#endif  spliceExpressions :: Splices -> [LHsExpr GhcTc] spliceExpressions Splices{..} =@@ -1258,10 +1237,8 @@        -> Util.StringBuffer -- ^ Haskell module source text (full Unicode is supported) #if MIN_VERSION_ghc(9,5,0)        -> ExceptT [FileDiagnostic] m ([FileDiagnostic], Located(HsModule GhcPs))-#elif MIN_VERSION_ghc(9,0,1)-       -> ExceptT [FileDiagnostic] m ([FileDiagnostic], Located(HsModule)) #else-       -> ExceptT [FileDiagnostic] m ([FileDiagnostic], Located(HsModule GhcPs))+       -> ExceptT [FileDiagnostic] m ([FileDiagnostic], Located(HsModule)) #endif parseHeader dflags filename contents = do    let loc  = mkRealSrcLoc (Util.mkFastString filename) 1 1
src/Development/IDE/GHC/CPP.hs view
@@ -21,16 +21,9 @@  -- See Note [Guidelines For Using CPP In GHCIDE Import Statements] -#if MIN_VERSION_ghc (8,10,0) && !MIN_VERSION_ghc(9,0,0)-import qualified DriverPipeline                  as Pipeline-import           ToolSettings-#endif--#if MIN_VERSION_ghc(9,0,0) import           GHC.Settings-#endif -#if MIN_VERSION_ghc(9,0,0) && !MIN_VERSION_ghc(9,3,0)+#if !MIN_VERSION_ghc(9,3,0) import qualified GHC.Driver.Pipeline             as Pipeline #endif 
src/Development/IDE/GHC/Compat.hs view
@@ -31,10 +31,6 @@     pattern PFailedWithErrorMessages,     isObjectLinkable, -#if !MIN_VERSION_ghc(9,0,1)-    RefMap,-#endif- #if MIN_VERSION_ghc(9,2,0) #if !MIN_VERSION_ghc(9,3,0)     extendModSummaryNoDeps,@@ -72,7 +68,6 @@     enrichHie,     writeHieFile,     readHieFile,-    supportsHieFiles,     setHieDir,     dontWriteHieFiles,     module Compat.HieTypes,@@ -170,39 +165,6 @@  -- See Note [Guidelines For Using CPP In GHCIDE Import Statements] -#if !MIN_VERSION_ghc(9,0,0)-import           Annotations                           (AnnTarget (ModuleTarget),-                                                        Annotation (..),-                                                        extendAnnEnvList)-import           ByteCodeAsm                           (bcoFreeNames)-import           ByteCodeGen                           (coreExprToBCOs)-import           CoreLint                              (lintInteractiveExpr)-import           CorePrep                              (corePrepExpr,-                                                        corePrepPgm)-import           CoreSyn                               (CoreExpr,-                                                        Unfolding (..),-                                                        flattenBinds,-                                                        noUnfolding)-import           CoreTidy                              (tidyExpr)-import           Hooks                                 (hscCompileCoreExprHook)-import           Linker                                (linkExpr)-import qualified SimplCore                             as GHC-import           UniqDFM-import           UniqDSet-import           UniqSet-import           VarEnv                                (emptyInScopeSet,-                                                        emptyTidyEnv, mkRnEnv2)-import           FastString-import qualified Avail-import           DynFlags                              hiding (ExposePackage)-import           HscTypes-import           MkIface                               hiding (writeIfaceFile)--import           StringBuffer                          (hPutStringBuffer)-import qualified SysTools-#endif--#if MIN_VERSION_ghc(9,0,0) import qualified GHC.Core.Opt.Pipeline                 as GHC import           GHC.Core.Tidy                         (tidyExpr) import           GHC.CoreToStg.Prep                    (corePrepPgm)@@ -224,16 +186,15 @@ import           GHC.Iface.Make                        (mkIfaceExports) import qualified GHC.SysTools.Tasks                    as SysTools import qualified GHC.Types.Avail                       as Avail-#endif -#if MIN_VERSION_ghc(9,0,0) && !MIN_VERSION_ghc(9,2,0)+#if !MIN_VERSION_ghc(9,2,0) import           GHC.Utils.Error import           GHC.CoreToByteCode                    (coreExprToBCOs) import           GHC.Runtime.Linker                    (linkExpr) import           GHC.Driver.Types #endif -#if MIN_VERSION_ghc(9,0,0) && !MIN_VERSION_ghc(9,5,0)+#if !MIN_VERSION_ghc(9,5,0) import           GHC.Core.Lint                         (lintInteractiveExpr) #endif @@ -400,14 +361,11 @@ getDependentMods :: ModIface -> [ModuleName] #if MIN_VERSION_ghc(9,3,0) getDependentMods = map (gwib_mod . snd) . S.toList . dep_direct_mods . mi_deps-#elif MIN_VERSION_ghc(9,0,0)-getDependentMods = map gwib_mod . dep_mods . mi_deps #else-getDependentMods = map fst . dep_mods . mi_deps+getDependentMods = map gwib_mod . dep_mods . mi_deps #endif  simplifyExpr :: DynFlags -> HscEnv -> CoreExpr -> IO CoreExpr-#if MIN_VERSION_ghc(9,0,0) #if MIN_VERSION_ghc(9,5,0) simplifyExpr _ env = GHC.simplifyExpr (Development.IDE.GHC.Compat.Env.hsc_logger env) (ue_eps (Development.IDE.GHC.Compat.Env.hsc_unit_env env)) (initSimplifyExprOpts (hsc_dflags env) (hsc_IC env)) #else@@ -423,10 +381,6 @@ corePrepExpr _ = GHC.corePrepExpr #endif -#else-simplifyExpr df _ = GHC.simplifyExpr df-#endif- renderMessages :: PsMessages -> (Bag WarnMsg, Bag ErrMsg) renderMessages msgs = #if MIN_VERSION_ghc(9,3,0)@@ -451,9 +405,6 @@ #endif {-# COMPLETE POk, PFailedWithErrorMessages #-} -supportsHieFiles :: Bool-supportsHieFiles = True- hieExportNames :: HieFile -> [(SrcSpan, Name)] hieExportNames = nameListFromAvails . hie_exports @@ -483,10 +434,6 @@ upNameCache = updNameCache #endif -#if !MIN_VERSION_ghc(9,0,1)-type RefMap a = Map.Map Identifier [(Span, IdentifierDetails a)]-#endif- mkHieFile' :: ModSummary            -> [Avail.AvailInfo]            -> HieASTs Type@@ -554,7 +501,6 @@   -#if MIN_VERSION_ghc(9,0,0) getNodeIds :: HieAST a -> Map.Map Identifier (IdentifierDetails a) getNodeIds = Map.foldl' combineNodeIds Map.empty . getSourcedNodeInfo . sourcedNodeInfo @@ -579,35 +525,11 @@     mergeSorted axs [] = axs     mergeSorted [] bxs = bxs -#else--getNodeIds :: HieAST a -> NodeIdentifiers a-getNodeIds = nodeIdentifiers . nodeInfo--- import qualified FastString as FS---- nodeInfo' :: HieAST TypeIndex -> NodeInfo TypeIndex-nodeInfo' :: Ord a => HieAST a -> NodeInfo a-nodeInfo' = nodeInfo--- type Unit = UnitId--- moduleUnit :: Module -> Unit--- moduleUnit = moduleUnitId--- unhelpfulSpanFS :: FS.FastString -> FS.FastString--- unhelpfulSpanFS = id-#endif- sourceNodeInfo :: HieAST a -> Maybe (NodeInfo a)-#if MIN_VERSION_ghc(9,0,0) sourceNodeInfo = Map.lookup SourceInfo . getSourcedNodeInfo . sourcedNodeInfo-#else-sourceNodeInfo = Just . nodeInfo-#endif  generatedNodeInfo :: HieAST a -> Maybe (NodeInfo a)-#if MIN_VERSION_ghc(9,0,0) generatedNodeInfo = Map.lookup GeneratedInfo . getSourcedNodeInfo . sourcedNodeInfo-#else-generatedNodeInfo = sourceNodeInfo -- before ghc 9.0, we don't distinguish the source-#endif  data GhcVersion   = GHC810@@ -677,11 +599,7 @@ #endif  mkAstNode :: NodeInfo a -> Span -> [HieAST a] -> HieAST a-#if MIN_VERSION_ghc(9,0,0) mkAstNode n = Node (SourcedNodeInfo $ Map.singleton GeneratedInfo n)-#else-mkAstNode = Node-#endif  combineRealSrcSpans :: RealSrcSpan -> RealSrcSpan -> RealSrcSpan #if MIN_VERSION_ghc(9,2,0)
src/Development/IDE/GHC/Compat/Core.hs view
@@ -40,9 +40,7 @@     readIface,     loadSysInterface,     importDecl,-#if MIN_VERSION_ghc(8,8,0)     CommandLineOption,-#endif #if !MIN_VERSION_ghc(9,2,0)     staticPlugins, #endif@@ -74,10 +72,6 @@     -- slightly unsafe     setUnsafeGlobalDynFlags,     -- * Linear Haskell-#if !MIN_VERSION_ghc(9,0,0)-    Scaled,-    unrestricted,-#endif     scaledThing,     -- * Interface Files     IfaceExport,@@ -95,12 +89,7 @@     mkPartialIface,     mkFullIface,     checkOldIface,-#if MIN_VERSION_ghc(9,0,0)     IsBootInterface(..),-#else-    pattern IsBoot,-    pattern NotBoot,-#endif     -- * Fixity     LexicalFixity(..),     Fixity (..),@@ -142,7 +131,6 @@     Development.IDE.GHC.Compat.Core.splitForAllTyCoVars, #endif     mkVisFunTys,-    Development.IDE.GHC.Compat.Core.mkInfForAllTys,     -- * Specs     ImpDeclSpec(..),     ImportSpec(..),@@ -276,7 +264,6 @@     Unlinked(..),     Linkable(..),     unload,-    initDynLinker,     -- * Hooks     Hooks,     runMetaHook,@@ -329,7 +316,6 @@     collectHsBindsBinders, #endif     -- * Util Module re-exports-#if MIN_VERSION_ghc(9,0,0)     module GHC.Builtin.Names,     module GHC.Builtin.Types,     module GHC.Builtin.Types.Prim,@@ -399,63 +385,12 @@     module GHC.Types.Unique.Supply,     module GHC.Types.Var,     module GHC.Unit.Module,-#else-    module BasicTypes,-    module Class,-    module Coercion,-    module Predicate,-    module ConLike,-    module CoreUtils,-    module DataCon,-    module DsExpr,-    module DsMonad,-    module ErrUtils,-    module FamInst,-    module FamInstEnv,-    module HeaderInfo,-    module Id,-    module InstEnv,-    module IfaceSyn,-    module Module,-    module Name,-    module NameCache,-    module NameEnv,-    module NameSet,-    module PatSyn,-    module PprTyThing,-    module PrelInfo,-    module PrelNames,-    module RdrName,-    module RnSplice,-    module RnNames,-    module TcEnv,-    module TcEvidence,-    module TcType,-    module TcRnTypes,-    module TcRnDriver,-    module TcRnMonad,-    module TyCon,-    module TysPrim,-    module TysWiredIn,-    module Type,-    module Unify,-    module UniqFM,-    module UniqSupply,-    module Var,-#endif     -- * Syntax re-exports-#if MIN_VERSION_ghc(9,0,0)     module GHC.Hs,     module GHC.Hs.Binds,     module GHC.Parser,     module GHC.Parser.Header,     module GHC.Parser.Lexer,-#else-    module GHC.Hs,-    module ExtractDocs,-    module Parser,-    module Lexer,-#endif #if MIN_VERSION_ghc(9,3,0)     CompileReason(..),     hsc_type_env_vars,@@ -509,94 +444,6 @@  -- See Note [Guidelines For Using CPP In GHCIDE Import Statements] -#if !MIN_VERSION_ghc(9,0,0)-import qualified Avail-import           BasicTypes                   hiding (Version)-import           Class-import           CmdLineParser                (Warn (..))-import           ConLike-import           CoreUtils-import           DataCon                      hiding (dataConExTyCoVars)-import qualified DataCon-import           DriverPhases-import           DriverPipeline-import           DsExpr-import           DsMonad                      hiding (foldrM)-import           DynFlags                     hiding (ExposePackage)-import qualified DynFlags-import           ErrUtils                     hiding (logInfo, mkWarnMsg)-import           ExtractDocs-import           FamInst-import           FamInstEnv-import           Finder                       hiding (mkHomeModLocation)-import           GHC.Hs                       hiding (HsLet, LetStmt)-import qualified GHCi-import           GhcMonad-import           HeaderInfo                   hiding (getImports)-import           Hooks-import           HscMain                      as GHC-import           HscTypes-import           Id-import           IfaceSyn-import           InstEnv-import           Lexer                        -import qualified Linker-import           LoadIface-import           MkIface                      as GHC-import           Module                       hiding (ModLocation (..), UnitId,-                                               addBootSuffixLocnOut,-                                               moduleUnitId)-import qualified Module-import           Name                         hiding (varName)-import           NameCache-import           NameEnv-import           NameSet-import           Packages-import           Panic                        hiding (try)-import qualified PlainPanic                   as Plain-import           Parser-import           PatSyn-import           RnFixity-import           Plugins-import           PprTyThing                   hiding (pprFamInst)-import           PrelInfo-import           PrelNames                    hiding (Unique, printName)-import           RdrName                      hiding (GRE, gre_name, gre_imp, gre_lcl, gre_par)-import qualified RdrName-import           RnNames-import           RnSplice-import qualified SrcLoc-import           TcEnv-import           TcEvidence                   hiding ((<.>))-import           TcIface-import           TcRnDriver-import           TcRnMonad                    hiding (Applicative (..), IORef,-                                               MonadFix (..), MonadIO (..),-                                               allM, anyM, concatMapM, foldrM,-                                               mapMaybeM, (<$>))-import           TcRnTypes-import           TcType-import           TidyPgm                     as GHC-import qualified TyCoRep-import           TyCon-import           Type-import           TysPrim-import           TysWiredIn-import           Unify-import           UniqFM hiding (UniqFM)-import qualified UniqFM-import           UniqSupply-import           Var                          (Var (varName), setTyVarUnique,-                                               setVarUnique, varType)--import           Coercion                     (coercionKind)-import           Predicate-import           SrcLoc                       (Located, SrcLoc (UnhelpfulLoc),-                                               SrcSpan (UnhelpfulSpan))-import qualified Finder as GHC-#endif--#if MIN_VERSION_ghc(9,0,0) import           GHC.Builtin.Names            hiding (Unique, printName) import           GHC.Builtin.Types import           GHC.Builtin.Types.Prim@@ -608,14 +455,13 @@ import qualified GHC.Core.DataCon             as DataCon import           GHC.Core.FamInstEnv          hiding (pprFamInst) import           GHC.Core.InstEnv-import           GHC.Types.Unique.FM hiding (UniqFM)-import qualified GHC.Types.Unique.FM          as UniqFM+import           GHC.Types.Unique.FM  import           GHC.Core.PatSyn import           GHC.Core.Predicate import           GHC.Core.TyCo.Ppr import qualified GHC.Core.TyCo.Rep            as TyCoRep import           GHC.Core.TyCon-import           GHC.Core.Type                hiding (mkInfForAllTys)+import           GHC.Core.Type                 import           GHC.Core.Unify import           GHC.Core.Utils import           GHC.Driver.CmdLine           (Warn (..))@@ -676,9 +522,8 @@ import           GHC.Utils.Error              (Severity (..), emptyMessages) import           GHC.Utils.Panic              hiding (try) import qualified GHC.Utils.Panic.Plain        as Plain-#endif -#if MIN_VERSION_ghc(9,0,0) && !MIN_VERSION_ghc(9,2,0)+#if !MIN_VERSION_ghc(9,2,0) import           GHC.Core.Ppr.TyThing         hiding (pprFamInst) import           GHC.Core.TyCo.Rep            (scaledThing) import           GHC.Driver.Finder hiding     (mkHomeModLocation)@@ -761,12 +606,6 @@ mkHomeModLocation = GHC.mkHomeModLocation #endif --#if !MIN_VERSION_ghc(9,0,0)-type BufSpan = ()-type BufPos = ()-#endif- #if MIN_VERSION_ghc(9,3,0) pattern RealSrcSpan :: SrcLoc.RealSrcSpan -> Maybe BufSpan -> SrcLoc.SrcSpan #else@@ -777,11 +616,8 @@ pattern RealSrcSpan x y <- SrcLoc.RealSrcSpan x ((\case Strict.Nothing -> Nothing; Strict.Just a -> Just a) -> y) where   RealSrcSpan x y = SrcLoc.RealSrcSpan x (case y of Nothing -> Strict.Nothing; Just a -> Strict.Just a) -#elif MIN_VERSION_ghc(9,0,0)-pattern RealSrcSpan x y = SrcLoc.RealSrcSpan x y #else-pattern RealSrcSpan x y <- ((,Nothing) -> (SrcLoc.RealSrcSpan x, y)) where-    RealSrcSpan x _ = SrcLoc.RealSrcSpan x+pattern RealSrcSpan x y = SrcLoc.RealSrcSpan x y #endif {-# COMPLETE RealSrcSpan, UnhelpfulSpan #-} @@ -790,12 +626,7 @@ #else pattern RealSrcLoc :: SrcLoc.RealSrcLoc -> Maybe BufPos-> SrcLoc.SrcLoc #endif-#if MIN_VERSION_ghc(9,0,0) pattern RealSrcLoc x y = SrcLoc.RealSrcLoc x y-#else-pattern RealSrcLoc x y <- ((,Nothing) -> (SrcLoc.RealSrcLoc x, y)) where-    RealSrcLoc x _ = SrcLoc.RealSrcLoc x-#endif {-# COMPLETE RealSrcLoc, UnhelpfulLoc #-}  @@ -839,7 +670,6 @@ pattern FunTy :: Type -> Type -> Type pattern FunTy arg res <- TyCoRep.FunTy {ft_arg = arg, ft_res = res} -#if MIN_VERSION_ghc(8,10,0) -- type HasSrcSpan x a = (GenLocated SrcSpan a ~ x) -- type HasSrcSpan x = () :: Constraint @@ -863,35 +693,11 @@ {-# COMPLETE L #-} #endif -#else-type HasSrcSpan = SrcLoc.HasSrcSpan-getLoc :: SrcLoc.HasSrcSpan a => a -> SrcLoc.SrcSpan-getLoc = SrcLoc.getLoc-#endif- -- | Add the @-boot@ suffix to all output file paths associated with the -- module, not including the input file itself addBootSuffixLocnOut :: GHC.ModLocation -> GHC.ModLocation addBootSuffixLocnOut = Module.addBootSuffixLocnOut -#if !MIN_VERSION_ghc(9,0,0)--- Linear Haskell-type Scaled a = a-scaledThing :: Scaled a -> a-scaledThing = id--unrestricted :: a -> Scaled a-unrestricted = id-#endif--mkInfForAllTys :: [TyVar] -> Type -> Type-mkInfForAllTys =-#if MIN_VERSION_ghc(9,0,0)-  TcType.mkInfForAllTys-#else-  mkInvForAllTys-#endif- #if !MIN_VERSION_ghc(9,2,0) splitForAllTyCoVars :: Type -> ([TyCoVar], Type) splitForAllTyCoVars =@@ -915,14 +721,6 @@   tcSplitForAllTy_maybe #endif --#if !MIN_VERSION_ghc(9,0,0)-pattern NotBoot, IsBoot :: IsBootInterface-pattern NotBoot = False-pattern IsBoot = True-#endif--#if MIN_VERSION_ghc(9,0,0) -- This is from the old api, but it still simplifies pattern ConPatIn :: SrcLoc.Located (ConLikeP GhcPs) -> HsConPatDetails GhcPs -> Pat GhcPs #if MIN_VERSION_ghc(9,2,0)@@ -932,36 +730,17 @@ #else pattern ConPatIn con args = ConPat NoExtField con args #endif-#endif  conPatDetails :: Pat p -> Maybe (HsConPatDetails p)-#if MIN_VERSION_ghc(9,0,0) conPatDetails (ConPat _ _ args) = Just args conPatDetails _ = Nothing-#else-conPatDetails (ConPatIn _ args) = Just args-conPatDetails _ = Nothing-#endif  mapConPatDetail :: (HsConPatDetails p -> Maybe (HsConPatDetails p)) -> Pat p -> Maybe (Pat p)-#if MIN_VERSION_ghc(9,0,0) mapConPatDetail f pat@(ConPat _ _ args) = (\args' -> pat { pat_args = args'}) <$> f args mapConPatDetail _ _ = Nothing-#else-mapConPatDetail f (ConPatIn ss args) = ConPatIn ss <$> f args-mapConPatDetail _ _ = Nothing-#endif  -initDynLinker, initObjLinker :: HscEnv -> IO ()-initDynLinker =-#if !MIN_VERSION_ghc(9,0,0)-    Linker.initDynLinker-#else-    -- It errors out in GHC 9.0 and doesn't exist in 9.2-    const $ return ()-#endif-+initObjLinker :: HscEnv -> IO () initObjLinker env = #if !MIN_VERSION_ghc(9,2,0)     GHCi.initObjLinker env@@ -1141,12 +920,6 @@ #if !MIN_VERSION_ghc_boot_th(9,4,1) pattern NamedFieldPuns :: Extension pattern NamedFieldPuns = RecordPuns-#endif--#if MIN_VERSION_ghc(9,0,0)-type UniqFM = UniqFM.UniqFM-#else-type UniqFM k = UniqFM.UniqFM #endif  #if MIN_VERSION_ghc(9,5,0)
src/Development/IDE/GHC/Compat/Env.hs view
@@ -57,20 +57,11 @@  -- See Note [Guidelines For Using CPP In GHCIDE Import Statements] -#if !MIN_VERSION_ghc(9,0,0)-import           DynFlags-import           Hooks-import           HscTypes                            as Env-import           Module-#endif--#if MIN_VERSION_ghc(9,0,0) import           GHC.Driver.Hooks                    (Hooks) import           GHC.Driver.Session                  hiding (mkHomeModule) import           GHC.Unit.Types                      (Module, UnitId)-#endif -#if MIN_VERSION_ghc(9,0,0) && !MIN_VERSION_ghc(9,2,0)+#if !MIN_VERSION_ghc(9,2,0) import qualified Data.Set                            as Set import qualified GHC.Driver.Session                  as DynFlags import           GHC.Driver.Types                    (HscEnv,@@ -78,12 +69,11 @@                                                       hsc_EPS,                                                       setInteractivePrintName) import qualified GHC.Driver.Types                    as Env-import           GHC.Driver.Ways                     hiding (hostFullWays)-import qualified GHC.Driver.Ways                     as Ways+import           GHC.Driver.Ways import           GHC.Unit.Types                      (Unit, mkModule) #endif -#if MIN_VERSION_ghc(9,0,0) && !MIN_VERSION_ghc(9,5,0)+#if !MIN_VERSION_ghc(9,5,0) import           GHC.Unit.Module.Name #endif @@ -95,8 +85,7 @@ import           GHC.Driver.Backend                  as Backend import qualified GHC.Driver.Env                      as Env import qualified GHC.Driver.Session                  as Session-import           GHC.Platform.Ways                   hiding (hostFullWays)-import qualified GHC.Platform.Ways                   as Ways+import           GHC.Platform.Ways import           GHC.Runtime.Context import           GHC.Unit.Env                        (UnitEnv) import           GHC.Unit.Home                       as Home@@ -130,10 +119,8 @@ setHomeUnitId_ :: UnitId -> DynFlags -> DynFlags #if MIN_VERSION_ghc(9,2,0) setHomeUnitId_ uid df = df { Session.homeUnitId_ = uid }-#elif MIN_VERSION_ghc(9,0,0)-setHomeUnitId_ uid df = df { homeUnitId = uid } #else-setHomeUnitId_ uid df = df { thisInstalledUnitId = toInstalledUnitId uid }+setHomeUnitId_ uid df = df { homeUnitId = uid } #endif  hscSetFlags :: DynFlags -> HscEnv -> HscEnv@@ -202,10 +189,8 @@ homeUnitId_ = #if MIN_VERSION_ghc(9,2,0)   Session.homeUnitId_-#elif MIN_VERSION_ghc(9,0,0)-  homeUnitId #else-  thisPackage+  homeUnitId #endif  safeImportsOn :: DynFlags -> Bool@@ -216,20 +201,16 @@   DynFlags.safeImportsOn #endif -#if MIN_VERSION_ghc(9,0,0) && !MIN_VERSION_ghc(9,2,0)+#if !MIN_VERSION_ghc(9,2,0) type HomeUnit = Unit-#elif !MIN_VERSION_ghc(9,0,0)-type HomeUnit = UnitId #endif  hscHomeUnit :: HscEnv -> HomeUnit hscHomeUnit = #if MIN_VERSION_ghc(9,2,0)   Env.hsc_home_unit-#elif MIN_VERSION_ghc(9,0,0)-  homeUnit . Env.hsc_dflags #else-  homeUnitId_ . hsc_dflags+  homeUnit . Env.hsc_dflags #endif  mkHomeModule :: HomeUnit -> ModuleName -> Module@@ -273,28 +254,16 @@ -- Ways helpers -- ------------------------------------------------------- -#if !MIN_VERSION_ghc(9,2,0) && MIN_VERSION_ghc(9,0,0)+#if !MIN_VERSION_ghc(9,2,0) type Ways = Set.Set Way-#elif !MIN_VERSION_ghc(9,0,0)-type Ways = [Way] #endif -hostFullWays :: Ways-hostFullWays =-#if MIN_VERSION_ghc(9,0,0)-  Ways.hostFullWays-#else-  interpWays-#endif- setWays :: Ways -> DynFlags -> DynFlags setWays newWays flags = #if MIN_VERSION_ghc(9,2,0)   flags { Session.targetWays_ = newWays}-#elif MIN_VERSION_ghc(9,0,0)-  flags {ways = newWays} #else-  updateWays $ flags {ways = newWays}+  flags {ways = newWays} #endif  -- -------------------------------------------------------
src/Development/IDE/GHC/Compat/Iface.hs view
@@ -12,13 +12,7 @@  -- See Note [Guidelines For Using CPP In GHCIDE Import Statements] -#if !MIN_VERSION_ghc(9,0,0)-import           Finder                                (FindResult)-import qualified Finder-import qualified MkIface-#endif--#if MIN_VERSION_ghc(9,0,0) && !MIN_VERSION_ghc(9,2,0)+#if !MIN_VERSION_ghc(9,2,0) import qualified GHC.Driver.Finder                     as Finder import           GHC.Driver.Types                      (FindResult) import qualified GHC.Iface.Load                        as Iface@@ -38,10 +32,8 @@ writeIfaceFile env fp iface = Iface.writeIface (hsc_logger env) (targetProfile $ hsc_dflags env) fp iface #elif MIN_VERSION_ghc(9,2,0) writeIfaceFile env fp iface = Iface.writeIface (hsc_logger env) (hsc_dflags env) fp iface-#elif MIN_VERSION_ghc(9,0,0)-writeIfaceFile env = Iface.writeIface (hsc_dflags env) #else-writeIfaceFile env = MkIface.writeIfaceFile (hsc_dflags env)+writeIfaceFile env = Iface.writeIface (hsc_dflags env) #endif  cannotFindModule :: HscEnv -> ModuleName -> FindResult -> SDoc
src/Development/IDE/GHC/Compat/Logger.hs view
@@ -15,16 +15,9 @@  -- See Note [Guidelines For Using CPP In GHCIDE Import Statements] -#if !MIN_VERSION_ghc(9,0,0)-import           DynFlags-import           Outputable                            (queryQual)-#endif--#if MIN_VERSION_ghc(9,0,0) import           GHC.Utils.Outputable-#endif -#if MIN_VERSION_ghc(9,0,0) && !MIN_VERSION_ghc(9,2,0)+#if !MIN_VERSION_ghc(9,2,0) import           GHC.Driver.Session                    as DynFlags #endif @@ -66,17 +59,10 @@ logActionCompat logAction logFlags _cls loc = logAction logFlags Nothing Nothing loc alwaysQualify  #else-#if MIN_VERSION_ghc(9,0,0) type LogActionCompat = DynFlags -> WarnReason -> Severity -> SrcSpan -> PrintUnqualified -> SDoc -> IO ()  -- alwaysQualify seems to still do the right thing here, according to the "unqualified warnings" test. logActionCompat :: LogActionCompat -> LogAction logActionCompat logAction dynFlags wr severity loc = logAction dynFlags wr severity loc alwaysQualify -#else-type LogActionCompat = DynFlags -> WarnReason -> Severity -> SrcSpan -> PrintUnqualified -> SDoc -> IO ()--logActionCompat :: LogActionCompat -> LogAction-logActionCompat logAction dynFlags wr severity loc style = logAction dynFlags wr severity loc (queryQual style)-#endif #endif
src/Development/IDE/GHC/Compat/Outputable.hs view
@@ -51,50 +51,35 @@  -- See Note [Guidelines For Using CPP In GHCIDE Import Statements] -#if !MIN_VERSION_ghc(9,0,0)-import           Development.IDE.GHC.Compat.Core (GlobalRdrEnv)-import           DynFlags-import           ErrUtils                        hiding (mkWarnMsg)-import qualified ErrUtils                        as Err-import           HscTypes-import           Outputable                      as Out hiding-                                                        (defaultUserStyle)-import qualified Outputable                      as Out-import           SrcLoc-#endif--#if MIN_VERSION_ghc(9,0,0) && !MIN_VERSION_ghc(9,2,0)+#if !MIN_VERSION_ghc(9,2,0) import           GHC.Driver.Session-import           GHC.Driver.Types                as HscTypes-import           GHC.Types.Name.Reader           (GlobalRdrEnv)+import           GHC.Driver.Types             as HscTypes+import           GHC.Types.Name.Reader        (GlobalRdrEnv) import           GHC.Types.SrcLoc-import           GHC.Utils.Error                 as Err hiding (mkWarnMsg)-import qualified GHC.Utils.Error                 as Err-import           GHC.Utils.Outputable            as Out hiding-                                                        (defaultUserStyle)-import qualified GHC.Utils.Outputable            as Out+import           GHC.Utils.Error              as Err hiding (mkWarnMsg)+import qualified GHC.Utils.Error              as Err+import           GHC.Utils.Outputable         as Out+import qualified GHC.Utils.Outputable         as Out #endif  #if MIN_VERSION_ghc(9,2,0) import           GHC.Driver.Env import           GHC.Driver.Ppr import           GHC.Driver.Session-import qualified GHC.Types.Error                 as Error+import qualified GHC.Types.Error              as Error import           GHC.Types.Name.Ppr import           GHC.Types.Name.Reader import           GHC.Types.SourceError import           GHC.Types.SrcLoc import           GHC.Unit.State-import           GHC.Utils.Error                 hiding (mkWarnMsg)-import           GHC.Utils.Outputable            as Out hiding-                                                        (defaultUserStyle)-import qualified GHC.Utils.Outputable            as Out+import           GHC.Utils.Error              hiding (mkWarnMsg)+import           GHC.Utils.Outputable         as Out import           GHC.Utils.Panic #endif  #if MIN_VERSION_ghc(9,2,0) && !MIN_VERSION_ghc(9,3,0) import           GHC.Parser.Errors-import qualified GHC.Parser.Errors.Ppr           as Ppr+import qualified GHC.Parser.Errors.Ppr        as Ppr #endif  #if MIN_VERSION_ghc(9,3,0)@@ -104,7 +89,7 @@ #endif  #if MIN_VERSION_ghc(9,5,0)-import           GHC.Driver.Errors.Types         (GhcMessage)+import           GHC.Driver.Errors.Types      (GhcMessage) #endif  #if MIN_VERSION_ghc(9,5,0)@@ -144,7 +129,7 @@     showSDocForUser unsafeGlobalDynFlags unqual doc #endif -#if MIN_VERSION_ghc(9,0,0) && !MIN_VERSION_ghc(9,2,0)+#if !MIN_VERSION_ghc(9,2,0) oldRenderWithStyle dflags sdoc sty = Out.renderWithStyle (initSDocContext dflags sty) sdoc oldMkUserStyle _ = Out.mkUserStyle oldMkErrStyle _ = Out.mkErrStyle@@ -152,18 +137,6 @@ oldFormatErrDoc :: DynFlags -> Err.ErrDoc -> Out.SDoc oldFormatErrDoc dflags = Err.formatErrDoc dummySDocContext   where dummySDocContext = initSDocContext dflags Out.defaultUserStyle-#elif !MIN_VERSION_ghc(9,0,0)-oldRenderWithStyle :: DynFlags -> Out.SDoc -> Out.PprStyle -> String-oldRenderWithStyle = Out.renderWithStyle--oldMkUserStyle :: DynFlags -> Out.PrintUnqualified -> Out.Depth -> Out.PprStyle-oldMkUserStyle = Out.mkUserStyle--oldMkErrStyle :: DynFlags -> Out.PrintUnqualified -> Out.PprStyle-oldMkErrStyle = Out.mkErrStyle--oldFormatErrDoc :: DynFlags -> Err.ErrDoc -> Out.SDoc-oldFormatErrDoc = Err.formatErrDoc #endif  #if !MIN_VERSION_ghc(9,3,0)@@ -263,13 +236,6 @@ #else   Err.mkWarnMsg #endif-#endif--defaultUserStyle :: PprStyle-#if MIN_VERSION_ghc(9,0,0)-defaultUserStyle = Out.defaultUserStyle-#else-defaultUserStyle = Out.defaultUserStyle unsafeGlobalDynFlags #endif  textDoc :: String -> SDoc
src/Development/IDE/GHC/Compat/Parser.hs view
@@ -6,7 +6,7 @@ module Development.IDE.GHC.Compat.Parser (     initParserOpts,     initParserState,-#if MIN_VERSION_ghc(9,0,0) && !MIN_VERSION_ghc(9,2,0)+#if !MIN_VERSION_ghc(9,2,0)     -- in GHC == 9.2 the type doesn't exist     -- In GHC == 9.0 it is a data-type     -- and GHC < 9.0 it is type-def@@ -16,9 +16,7 @@ #else     ApiAnns, #endif-#if MIN_VERSION_ghc(9,0,0)     PsSpan(..),-#endif #if MIN_VERSION_ghc(9,2,0)     pattern HsParsedModule,     type GHC.HsParsedModule,@@ -50,20 +48,11 @@  -- See Note [Guidelines For Using CPP In GHCIDE Import Statements] -#if !MIN_VERSION_ghc(9,0,0)-import qualified ApiAnnotation                   as Anno-import qualified HscTypes                        as GHC-import           Lexer-import qualified SrcLoc-#endif--#if MIN_VERSION_ghc(9,0,0) import qualified GHC.Parser.Annotation           as Anno import qualified GHC.Parser.Lexer                as Lexer import           GHC.Types.SrcLoc                (PsSpan (..))-#endif -#if MIN_VERSION_ghc(9,0,0) && !MIN_VERSION_ghc(9,2,0)+#if !MIN_VERSION_ghc(9,2,0) import qualified GHC.Driver.Types                as GHC #endif @@ -90,9 +79,7 @@ #endif  -#if !MIN_VERSION_ghc(9,0,0)-type ParserOpts = DynFlags-#elif !MIN_VERSION_ghc(9,2,0)+#if !MIN_VERSION_ghc(9,2,0) type ParserOpts = Lexer.ParserFlags #endif @@ -100,20 +87,16 @@ initParserOpts = #if MIN_VERSION_ghc(9,2,0)   Config.initParserOpts-#elif MIN_VERSION_ghc(9,0,0)-  Lexer.mkParserFlags #else-  id+  Lexer.mkParserFlags #endif  initParserState :: ParserOpts -> StringBuffer -> RealSrcLoc -> PState initParserState = #if MIN_VERSION_ghc(9,2,0)   Lexer.initParserState-#elif MIN_VERSION_ghc(9,0,0)-  Lexer.mkPStatePure #else-  Lexer.mkPState+  Lexer.mkPStatePure #endif  #if MIN_VERSION_ghc(9,2,0)@@ -164,7 +147,6 @@ mkApiAnns = const () #else mkApiAnns pst =-#if MIN_VERSION_ghc(9,0,1)     -- Copied from GHC.Driver.Main     Anno.ApiAnns {             apiAnnItems = Map.fromListWith (++) $ annotations pst,@@ -172,11 +154,6 @@             apiAnnComments = Map.fromList (annotations_comments pst),             apiAnnRogueComments = comment_q pst         }-#else-    (Map.fromListWith (++) $ annotations pst,-     Map.fromList ((SrcLoc.noSrcSpan,comment_q pst)-                  :annotations_comments pst))-#endif #endif  #if !MIN_VERSION_ghc(9,2,0)
src/Development/IDE/GHC/Compat/Plugins.hs view
@@ -25,21 +25,14 @@  -- See Note [Guidelines For Using CPP In GHCIDE Import Statements] -#if !MIN_VERSION_ghc(9,0,0)-import qualified DynamicLoading                        as Loader-import           Plugins-#endif--#if MIN_VERSION_ghc(9,0,0) import           GHC.Driver.Plugins                    (Plugin (..),                                                         PluginWithArgs (..),                                                         StaticPlugin (..),                                                         defaultPlugin,                                                         withPlugins) import qualified GHC.Runtime.Loader                    as Loader-#endif -#if MIN_VERSION_ghc(9,0,0) && !MIN_VERSION_ghc(9,3,0)+#if !MIN_VERSION_ghc(9,3,0) import           Development.IDE.GHC.Compat.Outputable as Out #endif 
src/Development/IDE/GHC/Compat/Units.hs view
@@ -26,7 +26,7 @@     unitExposedModules,     unitDepends,     unitHaddockInterfaces,-    unitInfoId,+    mkUnit,     unitPackageNameString,     unitPackageVersion,     -- * UnitId helpers@@ -34,9 +34,6 @@     Unit,     unitString,     stringToUnit,-#if !MIN_VERSION_ghc(9,0,0)-    pattern RealUnit,-#endif     definiteUnitId,     defUnitId,     installedModule,@@ -54,7 +51,6 @@     ) where  import           Data.Either-import           Data.Version import           Development.IDE.GHC.Compat.Core import           Development.IDE.GHC.Compat.Env import           Development.IDE.GHC.Compat.Outputable@@ -62,42 +58,27 @@  -- See Note [Guidelines For Using CPP In GHCIDE Import Statements] -#if !MIN_VERSION_ghc(9,0,0)-import qualified DynFlags-import           FastString-import qualified Finder                                as GHC-import           HscTypes-import           Module                                hiding (moduleUnitId)-import qualified Module-import           Packages                              (InstalledPackageInfo (haddockInterfaces, packageName),-                                                        LookupResult,-                                                        PackageConfig,-                                                        PackageConfigMap,-                                                        PackageState,-                                                        getPackageConfigMap,-                                                        lookupPackage')-import qualified Packages-#endif--#if MIN_VERSION_ghc(9,0,0) import           GHC.Types.Unique.Set import qualified GHC.Unit.Info                         as UnitInfo import           GHC.Unit.State                        (LookupResult, UnitInfo,-                                                        UnitState (unitInfoMap))+                                                        UnitState (unitInfoMap),+                                                        lookupUnit', mkUnit,+                                                        unitDepends,+                                                        unitExposedModules,+                                                        unitPackageNameString,+                                                        unitPackageVersion) import qualified GHC.Unit.State                        as State-import           GHC.Unit.Types                        hiding (moduleUnit,-                                                        toUnitId)+import           GHC.Unit.Types import qualified GHC.Unit.Types                        as Unit-#endif -#if MIN_VERSION_ghc(9,0,0) && !MIN_VERSION_ghc(9,2,0)+#if !MIN_VERSION_ghc(9,2,0) import           Data.Map                              (Map) import qualified GHC.Driver.Finder                     as GHC import qualified GHC.Driver.Session                    as DynFlags import           GHC.Driver.Types #endif -#if MIN_VERSION_ghc(9,0,0) && !MIN_VERSION_ghc(9,3,0)+#if !MIN_VERSION_ghc(9,3,0) import           GHC.Data.FastString  #endif@@ -125,37 +106,18 @@ #endif  -#if MIN_VERSION_ghc(9,0,0) type PreloadUnitClosure = UniqSet UnitId #if MIN_VERSION_ghc(9,2,0) type UnitInfoMap = State.UnitInfoMap #else type UnitInfoMap = Map UnitId UnitInfo #endif-#else-type UnitState = PackageState-type UnitInfo = PackageConfig-type UnitInfoMap = PackageConfigMap-type PreloadUnitClosure = ()-type Unit = UnitId-#endif --#if !MIN_VERSION_ghc(9,0,0)-unitString :: Unit -> String-unitString = Module.unitIdString--stringToUnit :: String -> Unit-stringToUnit = Module.stringToUnitId-#endif- unitState :: HscEnv -> UnitState #if MIN_VERSION_ghc(9,2,0) unitState = ue_units . hsc_unit_env-#elif MIN_VERSION_ghc(9,0,0)-unitState = DynFlags.unitState . hsc_dflags #else-unitState = DynFlags.pkgState . hsc_dflags+unitState = DynFlags.unitState . hsc_dflags #endif  #if MIN_VERSION_ghc(9,3,0)@@ -206,13 +168,9 @@ oldInitUnits :: DynFlags -> IO DynFlags #if MIN_VERSION_ghc(9,2,0) oldInitUnits = pure-#elif MIN_VERSION_ghc(9,0,0)-oldInitUnits dflags = do-  newFlags <- State.initUnits dflags-  pure newFlags #else oldInitUnits dflags = do-  newFlags <- fmap fst $ Packages.initPackages dflags+  newFlags <- State.initUnits dflags   pure newFlags #endif @@ -220,27 +178,17 @@ explicitUnits ue = #if MIN_VERSION_ghc(9,3,0)   map fst $ State.explicitUnits ue-#elif MIN_VERSION_ghc(9,0,0)-  State.explicitUnits ue #else-  Packages.explicitPackages ue+  State.explicitUnits ue #endif  listVisibleModuleNames :: HscEnv -> [ModuleName] listVisibleModuleNames env =-#if MIN_VERSION_ghc(9,0,0)   State.listVisibleModuleNames $ unitState env-#else-  Packages.listVisibleModuleNames $ hsc_dflags env-#endif  getUnitName :: HscEnv -> UnitId -> Maybe PackageName getUnitName env i =-#if MIN_VERSION_ghc(9,0,0)   State.unitPackageName <$> State.lookupUnitId (unitState env) i-#else-  packageName <$> Packages.lookupPackage (hsc_dflags env) (definiteUnitId (defUnitId i))-#endif  lookupModuleWithSuggestions   :: HscEnv@@ -252,92 +200,28 @@ #endif   -> LookupResult lookupModuleWithSuggestions env modname mpkg =-#if MIN_VERSION_ghc(9,0,0)   State.lookupModuleWithSuggestions (unitState env) modname mpkg-#else-  Packages.lookupModuleWithSuggestions (hsc_dflags env) modname mpkg-#endif  getUnitInfoMap :: HscEnv -> UnitInfoMap getUnitInfoMap = #if MIN_VERSION_ghc(9,2,0)   unitInfoMap . ue_units . hsc_unit_env-#elif MIN_VERSION_ghc(9,0,0)-  unitInfoMap . unitState #else-  Packages.getPackageConfigMap . hsc_dflags+  unitInfoMap . unitState #endif  lookupUnit :: HscEnv -> Unit -> Maybe UnitInfo-#if MIN_VERSION_ghc(9,0,0) lookupUnit env pid = State.lookupUnit (unitState env) pid-#else-lookupUnit env pid = Packages.lookupPackage (hsc_dflags env) pid-#endif -lookupUnit' :: Bool -> UnitInfoMap -> PreloadUnitClosure -> Unit -> Maybe UnitInfo-#if MIN_VERSION_ghc(9,0,0)-lookupUnit' = State.lookupUnit'-#else-lookupUnit' b pcm _ u = Packages.lookupPackage' b pcm u-#endif- preloadClosureUs :: HscEnv -> PreloadUnitClosure-#if MIN_VERSION_ghc(9,2,0) preloadClosureUs = State.preloadClosure . unitState-#elif MIN_VERSION_ghc(9,0,0)-preloadClosureUs = State.preloadClosure . unitState-#else-preloadClosureUs = const ()-#endif -unitExposedModules :: UnitInfo -> [(ModuleName, Maybe Module)]-unitExposedModules ue =-#if MIN_VERSION_ghc(9,0,0)-  UnitInfo.unitExposedModules ue-#else-  Packages.exposedModules ue-#endif--unitDepends :: UnitInfo -> [UnitId]-#if MIN_VERSION_ghc(9,0,0)-unitDepends = State.unitDepends-#else-unitDepends = fmap (Module.DefiniteUnitId. defUnitId') . Packages.depends-#endif--unitPackageNameString :: UnitInfo -> String-unitPackageNameString =-#if MIN_VERSION_ghc(9,0,0)-  UnitInfo.unitPackageNameString-#else-  Packages.packageNameString-#endif--unitPackageVersion :: UnitInfo -> Version-unitPackageVersion =-#if MIN_VERSION_ghc(9,0,0)-  UnitInfo.unitPackageVersion-#else-  Packages.packageVersion-#endif--unitInfoId :: UnitInfo -> Unit-unitInfoId =-#if MIN_VERSION_ghc(9,0,0)-  UnitInfo.mkUnit-#else-  Packages.packageConfigId-#endif- unitHaddockInterfaces :: UnitInfo -> [FilePath] unitHaddockInterfaces = #if MIN_VERSION_ghc(9,2,0)   fmap ST.unpack . UnitInfo.unitHaddockInterfaces-#elif MIN_VERSION_ghc(9,0,0)-  UnitInfo.unitHaddockInterfaces #else-  haddockInterfaces+  UnitInfo.unitHaddockInterfaces #endif  -- ------------------------------------------------------------------@@ -356,67 +240,26 @@ installedModule :: unit -> ModuleName -> GenModule unit installedModule        = Module -#elif MIN_VERSION_ghc(9,0,0)+#else definiteUnitId         = RealUnit defUnitId              = Definite installedModule        = Module -#else-pattern RealUnit :: Module.DefUnitId -> UnitId-pattern RealUnit x = Module.DefiniteUnitId x--definiteUnitId :: Module.DefUnitId -> UnitId-definiteUnitId = Module.DefiniteUnitId--defUnitId :: UnitId -> Module.DefUnitId-defUnitId = Module.DefUnitId . Module.toInstalledUnitId--defUnitId' :: Module.InstalledUnitId -> Module.DefUnitId-defUnitId' = Module.DefUnitId--installedModule :: UnitId -> ModuleName -> Module.InstalledModule-installedModule uid modname = Module.InstalledModule (Module.toInstalledUnitId uid) modname #endif -toUnitId :: Unit -> UnitId-toUnitId =-#if MIN_VERSION_ghc(9,0,0)-    Unit.toUnitId-#else-    id-#endif- moduleUnitId :: Module -> UnitId moduleUnitId =-#if MIN_VERSION_ghc(9,0,0)     Unit.toUnitId . Unit.moduleUnit-#else-    Module.moduleUnitId-#endif -moduleUnit :: Module -> Unit-moduleUnit =-#if MIN_VERSION_ghc(9,0,0)-    Unit.moduleUnit-#else-    Module.moduleUnitId-#endif- filterInplaceUnits :: [UnitId] -> [PackageFlag] -> ([UnitId], [PackageFlag]) filterInplaceUnits us packageFlags =   partitionEithers (map isInplace packageFlags)   where     isInplace :: PackageFlag -> Either UnitId PackageFlag     isInplace p@(ExposePackage _ (UnitIdArg u) _) =-#if MIN_VERSION_ghc(9,0,0)       if toUnitId u `elem` us         then Left $ toUnitId  u         else Right p-#else-      if u `elem` us-        then Left u-        else Right p-#endif     isInplace p = Right p  showSDocForUser' :: HscEnv -> PrintUnqualified -> SDoc -> String
src/Development/IDE/GHC/Compat/Util.hs view
@@ -71,24 +71,6 @@  -- See Note [Guidelines For Using CPP In GHCIDE Import Statements] -#if !MIN_VERSION_ghc(9,0,0)-import           Bag-import           BooleanFormula-import           EnumSet-import qualified Exception-import           FastString-import           Fingerprint-import           Maybes-import           Outputable              (pprHsString)-import           Pair-import           Panic                   hiding (try)-import           StringBuffer-import           UniqDFM-import           Unique-import           Util-#endif--#if MIN_VERSION_ghc(9,0,0) import           Control.Exception.Safe  (MonadCatch, catch, try) import           GHC.Data.Bag import           GHC.Data.BooleanFormula@@ -103,9 +85,8 @@ import           GHC.Utils.Fingerprint import           GHC.Utils.Outputable    (pprHsString) import           GHC.Utils.Panic         hiding (try)-#endif -#if MIN_VERSION_ghc(9,0,0) && !MIN_VERSION_ghc(9,3,0)+#if !MIN_VERSION_ghc(9,3,0) import           GHC.Utils.Misc #endif @@ -113,14 +94,3 @@ import           GHC.Data.Bool #endif --#if !MIN_VERSION_ghc(9,0,0)-type MonadCatch = Exception.ExceptionMonad---- We are using Safe here, which is not equivalent, but probably what we want.-catch :: (Exception.ExceptionMonad m, Exception e) => m a -> (e -> m a) -> m a-catch = Exception.gcatch--try :: (Exception.ExceptionMonad m, Exception e) => m a -> m (Either e a)-try = Exception.gtry-#endif
src/Development/IDE/GHC/CoreFile.hs view
@@ -27,19 +27,6 @@  -- See Note [Guidelines For Using CPP In GHCIDE Import Statements] -#if !MIN_VERSION_ghc(9,0,0)-import           Binary-import           BinFingerprint                  (fingerprintBinMem)-import           BinIface-import           CoreSyn-import           HscTypes-import           IfaceEnv-import           MkId-import           TcIface-import           ToIface-#endif--#if MIN_VERSION_ghc(9,0,0) import           GHC.Core import           GHC.CoreToIface import           GHC.Iface.Binary@@ -48,9 +35,8 @@ import           GHC.IfaceToCore import           GHC.Types.Id.Make import           GHC.Utils.Binary-#endif -#if MIN_VERSION_ghc(9,0,0) && !MIN_VERSION_ghc(9,2,0)+#if !MIN_VERSION_ghc(9,2,0) import           GHC.Driver.Types #endif 
src/Development/IDE/GHC/Orphans.hs view
@@ -20,24 +20,13 @@  -- See Note [Guidelines For Using CPP In GHCIDE Import Statements] -#if !MIN_VERSION_ghc(9,0,0)-import           Bag-import           ByteCodeTypes-import           GhcPlugins                 hiding (UniqFM)-import qualified StringBuffer               as SB-import           Unique                     (getKey)-#endif--#if MIN_VERSION_ghc(9,0,0) import           GHC.ByteCode.Types import           GHC.Data.Bag import           GHC.Data.FastString import qualified GHC.Data.StringBuffer      as SB import           GHC.Types.SrcLoc -#endif--#if MIN_VERSION_ghc(9,0,0) && !MIN_VERSION_ghc(9,3,0)+#if !MIN_VERSION_ghc(9,3,0) import           GHC                        (ModuleGraph) import           GHC.Types.Unique           (getKey) #endif@@ -78,22 +67,9 @@ instance Show InteractiveImport where show = unpack . printOutputable instance Show PackageName  where show = unpack . printOutputable -#if !MIN_VERSION_ghc(9,0,1)-instance Show ComponentId  where show = unpack . printOutputable-instance Show SourcePackageId  where show = unpack . printOutputable--instance Show GhcPlugins.InstalledUnitId where-    show = installedUnitIdString--instance NFData GhcPlugins.InstalledUnitId where rnf = rwhnf . installedUnitIdFS--instance Hashable GhcPlugins.InstalledUnitId where-  hashWithSalt salt = hashWithSalt salt . installedUnitIdString-#else instance Show UnitId where show = unpack . printOutputable deriving instance Ord SrcSpan deriving instance Ord UnhelpfulSpanReason-#endif  instance NFData SB.StringBuffer where rnf = rwhnf @@ -213,10 +189,8 @@  #if MIN_VERSION_ghc(9,5,0) instance (NFData (HsModule a)) where-#elif MIN_VERSION_ghc(9,0,1)-instance (NFData HsModule) where #else-instance (NFData (HsModule a)) where+instance (NFData HsModule) where #endif   rnf = rwhnf 
src/Development/IDE/GHC/Util.hs view
@@ -240,11 +240,7 @@  -- | This is copied unmodified from GHC since it is not exposed. -- Note the beautiful inline comment!-#if MIN_VERSION_ghc(9,0,0) dupHandle_ :: (RawIO dev, IODevice dev, BufferedIO dev, Typeable dev) => dev-#else-dupHandle_ :: (IODevice dev, BufferedIO dev, Typeable dev) => dev-#endif            -> FilePath            -> Maybe (MVar Handle__)            -> Handle__
src/Development/IDE/Import/FindImports.hs view
@@ -183,11 +183,7 @@      toModLocation uid file = liftIO $ do         loc <- mkHomeModLocation dflags (unLoc modName) (fromNormalizedFilePath file)-#if MIN_VERSION_ghc(9,0,0)         let genMod = mkModule (RealUnit $ Definite uid) (unLoc modName)  -- TODO support backpack holes-#else-        let genMod = mkModule uid (unLoc modName)-#endif         return $ Right $ FileImport $ ArtifactsLocation file (Just loc) (not isSource) (Just genMod)      lookupLocal uid dirs = do
src/Development/IDE/LSP/Outline.hs view
@@ -280,11 +280,6 @@ getConNames' :: ConDecl GhcPs -> [Located (IdP GhcPs)] getConNames' ConDeclH98  {con_name  = name}  = [name] getConNames' ConDeclGADT {con_names = names} = names-#if !MIN_VERSION_ghc(8,10,0)-getConNames' (XConDecl NoExt)                = []-#elif !MIN_VERSION_ghc(9,0,0)-getConNames' (XConDecl x)                    = noExtCon x-#endif #else hsConDeclsBinders :: LConDecl GhcPs                   -> ([LIdP GhcPs], [LFieldOcc GhcPs])
src/Development/IDE/Plugin/Completions/Types.hs view
@@ -27,15 +27,7 @@  -- See Note [Guidelines For Using CPP In GHCIDE Import Statements] -#if !MIN_VERSION_ghc(9,0,0)-import qualified OccName                      as Occ-#endif--#if MIN_VERSION_ghc(9,0,0) import qualified GHC.Types.Name.Occurrence    as Occ-#endif--  -- | Produce completions info for a file type instance RuleResult LocalCompletions = CachedCompletions
src/Development/IDE/Spans/AtPoint.hs view
@@ -167,12 +167,8 @@   -> MaybeT m [DocumentHighlight] documentHighlight hf rf pos = pure highlights   where-#if MIN_VERSION_ghc(9,0,1)     -- We don't want to show document highlights for evidence variables, which are supposed to be invisible     notEvidence = not . any isEvidenceContext . identInfo-#else-    notEvidence = const True-#endif     ns = concat $ pointCommand hf pos (rights . M.keys . M.filter notEvidence . getNodeIds)     highlights = do       n <- ns@@ -245,12 +241,8 @@          -- Check for evidence bindings         isInternal :: (Identifier, IdentifierDetails a) -> Bool-        isInternal (Right _, _dets) = -- dets is only used in GHC >= 9.0.1-#if MIN_VERSION_ghc(9,0,1)-          any isEvidenceContext $ identInfo _dets-#else-          False-#endif+        isInternal (Right _, dets) =+          any isEvidenceContext $ identInfo dets         isInternal (Left _, _) = False          filteredNames :: [(Identifier, IdentifierDetails hietype)]@@ -338,11 +330,7 @@             HAppTy a (HieArgs xs) -> getTypes' (a : map snd xs)             HTyConApp tc (HieArgs xs) -> ifaceTyConName tc : getTypes' (map snd xs)             HForAllTy _ a -> getTypes' [a]-#if MIN_VERSION_ghc(9,0,1)             HFunTy a b c -> getTypes' [a,b,c]-#else-            HFunTy a b -> getTypes' [a,b]-#endif             HQualTy a b -> getTypes' [a,b]             HCastTy a -> getTypes' [a]             _ -> []
src/Development/IDE/Spans/Documentation.hs view
@@ -172,13 +172,7 @@     sortedNameSpans :: [Located RdrName] -> [RealSrcSpan]     sortedNameSpans ls = nubSort (mapMaybe (realSpan . getLoc) ls)     isBetween target before after = before <= target && target <= after-#if MIN_VERSION_ghc(9,0,0)     ann = apiAnnComments . pm_annotations-#else-    ann = fmap filterReal . snd . pm_annotations-    filterReal :: [Located a] -> [RealLocated a]-    filterReal = mapMaybe (\(L l v) -> (`L`v) <$> realSpan l)-#endif     annotationFileName :: ParsedModule -> Maybe FastString     annotationFileName = fmap srcSpanFile . listToMaybe . map getRealSrcSpan . fold . ann 
src/Development/IDE/Spans/Pragmas.hs view
@@ -303,11 +303,7 @@ lexUntilNextLineIncl :: P (Located Token) lexUntilNextLineIncl = do   PState{ last_loc } <- getPState-#if MIN_VERSION_ghc(9,0,0)   let PsSpan{ psRealSpan = lastRealSrcSpan } = last_loc-#else-  let lastRealSrcSpan = last_loc-#endif   let prevEndLine = lastRealSrcSpan & realSrcSpanEnd & srcLocLine   locatedToken@(L srcSpan _token) <- lexer False pure   if | RealSrcLoc currEndRealSrcLoc _ <- srcSpan & srcSpanEnd
src/Development/IDE/Types/HscEnvEq.hs view
@@ -91,7 +91,7 @@                         -- When module is re-exported from another package,                         -- the origin module is represented by value in Just                         Just otherPkgMod -> otherPkgMod-                        Nothing          -> mkModule (unitInfoId pkg) modName+                        Nothing          -> mkModule (mkUnit pkg) modName                 ]              doOne m = do
src/Development/IDE/Types/Location.hs view
@@ -38,15 +38,8 @@  -- See Note [Guidelines For Using CPP In GHCIDE Import Statements] -#if !MIN_VERSION_ghc(9,0,0)-import           FastString-import           SrcLoc                       as GHC-#endif--#if MIN_VERSION_ghc(9,0,0) import           GHC.Data.FastString import           GHC.Types.SrcLoc             as GHC-#endif  toNormalizedFilePath' :: FilePath -> LSP.NormalizedFilePath -- We want to keep empty paths instead of normalising them to "."
test/exe/CompletionTests.hs view
@@ -261,7 +261,7 @@       []   ]   where-    brokenForWinGhc = knownBrokenFor (BrokenSpecific Windows [GHC810, GHC90, GHC92, GHC94, GHC96]) "Windows has strange things in scope for some reason"+    brokenForWinGhc = knownBrokenFor (BrokenSpecific Windows [GHC90, GHC92, GHC94, GHC96]) "Windows has strange things in scope for some reason"  otherCompletionTests :: [TestTree] otherCompletionTests = [
test/exe/FindDefinitionAndHoverTests.hs view
@@ -205,10 +205,7 @@   , test  yes    yes    lclL33     lcb           "listcomp lookup"   , test  yes    yes    mclL36     mcl           "top-level fn 1st clause"   , test  yes    yes    mclL37     mcl           "top-level fn 2nd clause         #1030"-  , if ghcVersion >= GHC810 then-        test  yes    yes    spaceL37   space         "top-level fn on space           #1002"-    else-        test  yes    broken spaceL37   space         "top-level fn on space           #1002"+  , test  yes    yes    spaceL37   space         "top-level fn on space           #1002"   , test  no     yes    docL41     doc           "documentation                   #1129"   , test  no     yes    eitL40     kindE         "kind of Either                  #1017"   , test  no     yes    intL40     kindI         "kind of Int                     #1017"
test/exe/HighlightTests.hs view
@@ -50,19 +50,13 @@         _ <- waitForDiagnostics         highlights <- getHighlights doc (Position 4 15)         liftIO $ highlights @?=-          -- Span is just the .. on 8.10, but Rec{..} before-          [ if ghcVersion >= GHC810-            then DocumentHighlight (R 4 8 4 10) (Just DocumentHighlightKind_Write)-            else DocumentHighlight (R 4 4 4 11) (Just DocumentHighlightKind_Write)+          [ DocumentHighlight (R 4 8 4 10) (Just DocumentHighlightKind_Write)           , DocumentHighlight (R 4 14 4 20) (Just DocumentHighlightKind_Read)           ]         highlights <- getHighlights doc (Position 3 17)         liftIO $ highlights @?=           [ DocumentHighlight (R 3 17 3 23) (Just DocumentHighlightKind_Write)-          -- Span is just the .. on 8.10, but Rec{..} before-          , if ghcVersion >= GHC810-              then DocumentHighlight (R 4 8 4 10) (Just DocumentHighlightKind_Read)-              else DocumentHighlight (R 4 4 4 11) (Just DocumentHighlightKind_Read)+          , DocumentHighlight (R 4 8 4 10) (Just DocumentHighlightKind_Read)           ]   ]   where
test/exe/PluginParsedResultTests.hs view
@@ -10,7 +10,6 @@  tests :: TestTree tests =-  ignoreInWindowsForGHC810 $   ignoreForGHC92Plus "No need for this plugin anymore!" $   testSessionWithExtraFiles "plugin-recorddot" "parsedResultAction plugin" $ \dir -> do     _ <- openDoc (dir</> "RecordDot.hs") "haskell"
test/exe/PluginSimpleTests.hs view
@@ -15,7 +15,6 @@  tests :: TestTree tests =-  ignoreInWindowsForGHC810 $   -- Build profile: -w ghc-9.4.2 -O1   -- In order, the following will be built (use -v for more details):   -- - ghc-typelits-natnormalise-0.7.7 (lib) (requires build)
test/exe/TestUtils.hs view
@@ -166,10 +166,6 @@ ignoreInWindowsBecause :: String -> TestTree -> TestTree ignoreInWindowsBecause = ignoreFor (BrokenForOS Windows) -ignoreInWindowsForGHC810 :: TestTree -> TestTree-ignoreInWindowsForGHC810 =-    ignoreFor (BrokenSpecific Windows [GHC810]) "tests are unreliable in windows for ghc 8.10"- ignoreForGHC92Plus :: String -> TestTree -> TestTree ignoreForGHC92Plus = ignoreFor (BrokenForGHC [GHC92, GHC94, GHC96])