From d891e5ac3a3ea91a8a2238e86eae7fcf340d1f91 Mon Sep 17 00:00:00 2001 From: Paul Wright <68547250+polmacanceart@users.noreply.github.com> Date: Mon, 25 Jan 2021 12:33:38 +0000 Subject: [PATCH] Fix to exclude strings from toggle coverage (#2766) (#2767) --- src/V3AstNodes.h | 2 +- test_regress/t/t_cover_toggle.v | 4 +++- 2 files changed, 4 insertions(+), 2 deletions(-) diff --git a/src/V3AstNodes.h b/src/V3AstNodes.h index b6bb6653a..feebe0714 100644 --- a/src/V3AstNodes.h +++ b/src/V3AstNodes.h @@ -2170,7 +2170,7 @@ public: return ((isIO() || isSignal()) && (isIO() || isBitLogic()) // Wrapper would otherwise duplicate wrapped module's coverage - && !isSc() && !isPrimaryIO() && !isConst() && !isDouble()); + && !isSc() && !isPrimaryIO() && !isConst() && !isDouble() && !isString()); } bool isClassMember() const { return varType() == AstVarType::MEMBER; } bool isStatementTemp() const { return (varType() == AstVarType::STMTTEMP); } diff --git a/test_regress/t/t_cover_toggle.v b/test_regress/t/t_cover_toggle.v index 1c4008c3b..eb8e24ae2 100644 --- a/test_regress/t/t_cover_toggle.v +++ b/test_regress/t/t_cover_toggle.v @@ -7,11 +7,13 @@ module t (/*AUTOARG*/ // Inputs clk, - check_real + check_real, + check_string ); input clk; input real check_real; // Check issue #2741 + input string check_string; // Check issue #2766 typedef struct packed { union packed {