import qualified Data.Foldable as Foldable
import Control.Applicative
import Outputable ( showSDoc, ppr )
-import qualified Control.Monad.State as State
+import qualified Control.Monad.Trans.State as State
import HsValueMap
import TranslatorTypes
flattenBuildTupleExpr binds args = do
-- Flatten each of our args
- flat_args <- (State.mapM (flattenExpr binds) args)
+ flat_args <- (mapM (flattenExpr binds) args)
-- Check and split each of the arguments
let (_, arg_ress) = unzip (zipWith checkArg args flat_args)
let res = Tuple arg_ress
-- Find the function to call
let func = appToHsFunction ty f args
-- Flatten each of our args
- flat_args <- (State.mapM (flattenExpr binds) args)
+ flat_args <- (mapM (flattenExpr binds) args)
-- Check and split each of the arguments
let (_, arg_ress) = unzip (zipWith checkArg args flat_args)
-- Generate signals for our result