struct conversion handles decls with unpacked dimensions

This commit is contained in:
Zachary Snow 2019-04-23 15:37:47 -04:00
parent 5583eaeca8
commit 4e34217472
1 changed files with 3 additions and 1 deletions

View File

@ -159,7 +159,9 @@ collectTFArgsM _ = return ()
traverseDeclM :: Decl -> State Types Decl
traverseDeclM origDecl = do
case origDecl of
Variable _ t x _ _ -> modify $ Map.insert x t
Variable _ t x a _ -> do
let (tf, rs) = typeRanges t
modify $ Map.insert x (tf $ a ++ rs)
Parameter t x _ -> modify $ Map.insert x t
Localparam t x _ -> modify $ Map.insert x t
return origDecl