Re: [PATCH v3 09/13] qapi/parser: add import cycle workaround

2021-09-30 Thread John Snow
On Thu, Sep 30, 2021 at 5:45 AM Markus Armbruster wrote: > John Snow writes: > > > There is a cycle that exists in the QAPI generator: [schema -> expr -> > > "There is" or "there will be once we add strong type hints"? > > "There exists in my mind-palace a cycle where, ..." (Will adjust the com

Re: [PATCH v3 09/13] qapi/parser: add import cycle workaround

2021-09-30 Thread Markus Armbruster
John Snow writes: > There is a cycle that exists in the QAPI generator: [schema -> expr -> "There is" or "there will be once we add strong type hints"? > parser -> schema]. It exists because the QAPIDoc class needs the names > of types defined by the schema module, but the schema module needs t

[PATCH v3 09/13] qapi/parser: add import cycle workaround

2021-09-29 Thread John Snow
There is a cycle that exists in the QAPI generator: [schema -> expr -> parser -> schema]. It exists because the QAPIDoc class needs the names of types defined by the schema module, but the schema module needs to import both expr.py/parser.py to do its actual parsing. Ultimately, the layering viola