# VHDL317: A function or procedure should not have too many parameters ## Summary ```{raw} html

Count: 1

ReliabilitySecurityMaintainabilityCode attributeEffort to fixTags
--MEDIUMAdaptability | Focused20minsynthesis, vscode, linter, simulation
``` ## Description ```{raw} html

Noncompliant code example

With default maximum number of parameters: 3

function too_many_responsibilities (length, width, height, color: integer) return integer;

Compliant solution

With default maximum number of parameters: 3

function single_responsibility (length, width, height: integer) return integer;

A function or procedure should have a single and well-defined responsibility. Such a function is easier to understand, change, maintain, test and reuse. Too many parameters is an indication that the function/procedure has too many responsibilities.

Articles & blog posts

``` ## Parameters ```{raw} html

Count: 1

ParameterValueDescription
max3The maximum allowed number of parameters.
``` ```{raw} html ```