Better error for unsupported SVA sequence
authorMiodrag Milanovic <mmicko@gmail.com>
Fri, 18 Sep 2020 15:08:00 +0000 (17:08 +0200)
committerMiodrag Milanovic <mmicko@gmail.com>
Fri, 18 Sep 2020 15:08:00 +0000 (17:08 +0200)
frontends/verific/verificsva.cc

index 49c0c40acce7d0dd3f5018d121fc7763b8c8d12d..632043b6f091ef22e3b10e3f5a25481f3b087206 100644 (file)
@@ -1040,8 +1040,14 @@ struct VerificSvaImporter
 
        [[noreturn]] void parser_error(Instance *inst)
        {
-               parser_error(stringf("Verific SVA primitive %s (%s) is currently unsupported in this context",
-                               inst->View()->Owner()->Name(), inst->Name()), inst->Linefile());
+               std::string msg;
+               if (inst->Type() == PRIM_SVA_MATCH_ITEM_TRIGGER || inst->Type() == PRIM_SVA_MATCH_ITEM_ASSIGN)
+               {
+                       msg = "SVA sequences with local variable assignments are currently not supported.\n";
+               }
+
+               parser_error(stringf("%sVerific SVA primitive %s (%s) is currently unsupported in this context",
+                               msg.c_str(), inst->View()->Owner()->Name(), inst->Name()), inst->Linefile());
        }
 
        dict<Net*, bool, hash_ptr_ops> check_expression_cache;