Commit 6e4a19d0 by Zachary Snow

flatten generate blocks with one item

parent dd0eb598
......@@ -141,6 +141,7 @@ traverseModuleItemsM mapper (Part attrs extern kw lifetime name ports items) = d
_ -> GenModuleItem moduleItem'
genItemMapper (GenIf (Number "1") s _) = return s
genItemMapper (GenIf (Number "0") _ s) = return s
genItemMapper (GenBlock "" [item]) = return item
genItemMapper (GenBlock _ []) = return GenNull
genItemMapper other = return other
breakGenerate :: ModuleItem -> [ModuleItem]
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment