Re: [PATCH v4 3/5] dts: add parsing utility module

2024-06-06 Thread Luca Vizzarro
On 06/06/2024 19:52, Jeremy Spewock wrote: +@classmethod +def from_str(cls, text: str): +match text: +case "black": +return cls.BLACK +case "white": +

Re: [PATCH v4 3/5] dts: add parsing utility module

2024-06-06 Thread Jeremy Spewock
Just a few very minor documentation catches, otherwise: Reviewed-by: Jeremy Spewock On Thu, Jun 6, 2024 at 5:17 AM Luca Vizzarro wrote: > +@classmethod > +def from_str(cls, text: str): > +match text: > +case "black": >

[PATCH v4 3/5] dts: add parsing utility module

2024-06-06 Thread Luca Vizzarro
Adds parsing text into a custom dataclass. It provides a new `TextParser` dataclass to be inherited. This implements the `parse` method, which combined with the parser functions, it can automatically parse the value for each field. This new utility will facilitate and simplify the parsing of compl