Re: [RFC PATCH 05/17] verification/rvgen: Annotate DA functions with types

From: Nam Cao
Date: Thu Aug 21 2025 - 04:38:42 EST


On Thu, Aug 14, 2025 at 05:07:57PM +0200, Gabriele Monaco wrote:
> Functions in automata.py, dot2c.py and dot2k.py don't have type
> annotations and it can get complicated to remember how to use them.
>
> Add minimal type annotations.

Nice, Python is sometimes hard to read because the type is not clear.

> - def __get_event_variables(self):
> + def __get_event_variables(self) -> tuple[list[str], list[str]]:

This annotation is wrong. It becomes correct only after your later patch
(verification/rvgen: Add support for Hybrid Automata)

The rest looks good.

Nam