Issue#1361: Added rule array_constraint_500.

This commit is contained in:
JHertz5 2024-12-21 11:21:34 +00:00
parent cc25b139c6
commit fdafb60e2c
3 changed files with 36 additions and 0 deletions

View File

@ -111,6 +111,7 @@ from vsg.rules import alias_declaration
from vsg.rules import after
from vsg.rules import aggregate
from vsg.rules import architecture
from vsg.rules import array_constraint
from vsg.rules import assert_statement
from vsg.rules import attribute
from vsg.rules import attribute_declaration

View File

@ -0,0 +1,3 @@
# -*- coding: utf-8 -*-
from .rule_500 import rule_500

View File

@ -0,0 +1,32 @@
# -*- coding: utf-8 -*-
from vsg import token
from vsg.rules import token_case
lTokens = []
lTokens.append(token.array_constraint.open_keyword)
class rule_500(token_case):
"""
This rule checks the **open** keyword in array constraints has the proper case.
|configuring_uppercase_and_lowercase_rules_link|
**Violation**
.. code-block:: vhdl
subtype t_my_array is t_array(OPEN)(t_range);
**Fix**
.. code-block:: vhdl
subtype t_my_array is t_array(open)(t_range);
"""
def __init__(self):
super().__init__(lTokens)
self.groups.append("case::keyword")