hls-tactics-plugin-1.1.0.0: Wingman plugin for Haskell Language Server
Safe HaskellNone
LanguageHaskell2010

Wingman.Naming

Synopsis

Documentation

mkTyName :: Type -> String Source #

Use type information to create a reasonable name.

mkTyConName :: TyCon -> String Source #

Get a good name for a type constructor.

filterReplace :: (a -> Bool) -> a -> [a] -> [a] Source #

Maybe replace an element in the list if the predicate matches

mkGoodName Source #

Arguments

:: Set OccName

Bindings in scope; used to ensure we don't shadow anything

-> Type

The type to produce a name for

-> OccName 

Produce a unique, good name for a type.

mkManyGoodNames :: (Traversable t, Monad m) => Set OccName -> t Type -> m (t OccName) Source #

Like mkGoodName but creates several apart names.

getInScope :: Map OccName a -> [OccName] Source #

Which names are in scope?