Skip to content

Commit 1c64a6a

Browse files
committed
Update ModuleCanonicalizer.scala
1 parent ed87bcd commit 1c64a6a

File tree

1 file changed

+0
-2
lines changed

1 file changed

+0
-2
lines changed

src/main/scala/uclid/lang/ModuleCanonicalizer.scala

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -44,8 +44,6 @@ class ModuleCanonicalizerPass extends RewritePass {
4444
override def rewriteModule(moduleIn : Module, ctx : Scope) : Option[Module] = {
4545
// Currently we only allow one init and one next block in a module.
4646
// we could alternatively, combine multiple init (or next) blocks into a single init (or next) block.
47-
if(moduleIn.decls.filter(_.isInstanceOf[InitDecl]).map(_.asInstanceOf[InitDecl]).size > 1) {
48-
throw new Exception("Module " + moduleIn.id + " has more than one init block. This is not allowed.")
4947
var errors: List[(String, lang.ASTPosition)] = List.empty
5048
val initdecls = moduleIn.decls.filter(_.isInstanceOf[InitDecl]).map(_.asInstanceOf[InitDecl])
5149
if(initdecls.size > 1) {

0 commit comments

Comments
 (0)