From 9741b1a94f02482abdcf4de11cf0d3090012b299 Mon Sep 17 00:00:00 2001 From: Matthijs Kooijman Date: Thu, 22 Jan 2009 17:37:14 +0100 Subject: [PATCH] Make getPortMapEntry accept a PortNameMap. --- Translator.hs | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/Translator.hs b/Translator.hs index 1b2d24b..b18a86f 100644 --- a/Translator.hs +++ b/Translator.hs @@ -82,7 +82,7 @@ findBind lookfor = -- Accepts a port name and an argument to map to it. -- Returns the appropriate line for in the port map -getPortMapEntry binds portname (Var id) = +getPortMapEntry binds (Port portname) (Var id) = (Just (AST.unsafeVHDLBasicId portname)) AST.:=>: (AST.ADName (AST.NSimple (AST.unsafeVHDLBasicId signalname))) where Port signalname = Maybe.fromMaybe @@ -148,7 +148,7 @@ getInstantiations sess args outs binds app@(App expr arg) = (lookup compname (funcs sess)) HWFunction inports outports = hwfunc ports = - zipWith (getPortMapEntry binds) ["portin0", "portin1"] fargs + zipWith (getPortMapEntry binds) [Port "portin0", Port "portin1"] fargs ++ mapOutputPorts outports outs getInstantiations sess args outs binds expr = -- 2.30.2