From 303b3a0eeb8533ef877535880e52c7fde2451bb2 Mon Sep 17 00:00:00 2001 From: Jorge Marques Date: Mon, 25 Sep 2023 17:53:42 -0300 Subject: [PATCH] docs: add check for signals/bus Signals/buses declared in the docs that does not exist in the components.xml files will raise a warning. Signed-off-by: Jorge Marques --- docs/extensions/adi_hdl_parser.py | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/docs/extensions/adi_hdl_parser.py b/docs/extensions/adi_hdl_parser.py index d18ed95af..fd8d7d895 100644 --- a/docs/extensions/adi_hdl_parser.py +++ b/docs/extensions/adi_hdl_parser.py @@ -337,6 +337,10 @@ class directive_interfaces(directive_base): subnode += section + for tag in description: + if tag not in bs and tag not in pr: + logger.warning(f"Signal {tag} defined in the directive does not exist in the source code!") + return subnode def run(self): @@ -515,7 +519,7 @@ class directive_parameters(directive_base): for tag in description: if tag not in parameter: - logger.warning(f"{tag} does not exist in {file_2}!") + logger.warning(f"{tag} defined in the directive does not exist in the source code!") return table