VHDL134: All declared elements should be used in their corresponding scope

Summary

Count: 1

ReliabilitySecurityMaintainabilityCode attributeEffort to fixTags
MEDIUM-MEDIUMIntentionality | Clear20minsynthesis, do254-cp14, do254, vscode, simulation, linter, cnes, cnes-std-03100

Description

All declared elements should be used in their corresponding scope. Useless declarations should be removed.

Noncompliant code example

procedure proc is
  variable tmp: std_logic;
  constant cst: std_logic := '0';
  constant other_cst: std_logic := '1'; -- Noncompliant: "other_cst" is not used
begin
  tmp <= cst;
end proc;

Compliant solution

procedure proc is
  variable tmp: std_logic;
  constant cst: std_logic := '0';
begin
  tmp <= cst;
end proc;

Parameters

No parameters.