From: Matthijs Kooijman Date: Fri, 6 Mar 2009 10:23:00 +0000 (+0100) Subject: Add a getFuncMap accessor for VHDLState. X-Git-Url: https://git.stderr.nl/gitweb?a=commitdiff_plain;h=53b8d7183c05b1c1248875bf3a9394a0a7af5518;p=matthijs%2Fmaster-project%2Fc%CE%BBash.git Add a getFuncMap accessor for VHDLState. --- diff --git a/TranslatorTypes.hs b/TranslatorTypes.hs index d508816..40529ea 100644 --- a/TranslatorTypes.hs +++ b/TranslatorTypes.hs @@ -76,6 +76,10 @@ modFunc :: (FuncData -> FuncData) -> HsFunction -> VHDLState () modFunc f hsfunc = modFuncMap (Map.adjust f hsfunc) +-- | Get the map of functions in the session +getFuncMap :: VHDLState FuncMap +getFuncMap = State.gets funcs + -- | Modify the function map in the session using the given function modFuncMap :: (FuncMap -> FuncMap) -> VHDLState () modFuncMap f = do