Removed the code for initialising members - it is unneeded, and will no longer work until the ensuing _sizes declaration

This commit is contained in:
Neil Brown 2008-03-08 00:09:28 +00:00
parent a4646f88fa
commit 3c070f035c
2 changed files with 1 additions and 7 deletions

View File

@ -1229,9 +1229,6 @@ cdeclareInit m t@(A.Array ds t') var _
sequence_ $ intersperse (tell ["*"]) [case dim of A.Dimension d -> tell [show d] | dim <- ds]
tell [");"]
_ -> return ()
fdeclareInit <- fget declareInit
init <- return (\sub -> fdeclareInit m t' (sub var) Nothing)
call genOverArray m var init
cdeclareInit m rt@(A.Record _) var _
= Just $ do fs <- recordFields m rt
sequence_ [initField t (A.SubscriptedVariable m (A.SubscriptField m n) var)

View File

@ -515,10 +515,7 @@ cppgenProcCall n as
-- | Changed because we initialise channels and arrays differently in C++
cppdeclareInit :: Meta -> A.Type -> A.Variable -> Maybe A.Expression -> Maybe (CGen ())
cppdeclareInit m t@(A.Array ds t') var _
= Just $ do fdeclareInit <- fget declareInit
init <- return (\sub -> fdeclareInit m t' (sub var) Nothing)
call genOverArray m var init
case t' of
= Just $ do case t' of
A.Chan A.DirUnknown _ _ ->
do tell ["tockInitChanArray("]
call genVariableUnchecked var