Re: [PATCH v4 39/46] qapi/introspect.py: Unify return type of _make_tree()

2020-09-30 Thread John Snow
On 9/30/20 2:57 PM, Eduardo Habkost wrote: On Wed, Sep 30, 2020 at 02:32:49PM -0400, John Snow wrote: On 9/30/20 2:24 PM, Eduardo Habkost wrote: On Wed, Sep 30, 2020 at 12:31:43AM -0400, John Snow wrote: Returning a *something* or a Tuple of *something* is hard to accurately type. Let's just a

Re: [PATCH v4 39/46] qapi/introspect.py: Unify return type of _make_tree()

2020-09-30 Thread Eduardo Habkost
On Wed, Sep 30, 2020 at 02:32:49PM -0400, John Snow wrote: > On 9/30/20 2:24 PM, Eduardo Habkost wrote: > > On Wed, Sep 30, 2020 at 12:31:43AM -0400, John Snow wrote: > > > Returning a *something* or a Tuple of *something* is hard to accurately > > > type. Let's just always return a tuple for struc

Re: [PATCH v4 39/46] qapi/introspect.py: Unify return type of _make_tree()

2020-09-30 Thread John Snow
On 9/30/20 2:24 PM, Eduardo Habkost wrote: On Wed, Sep 30, 2020 at 12:31:43AM -0400, John Snow wrote: Returning a *something* or a Tuple of *something* is hard to accurately type. Let's just always return a tuple for structural consistency. Instances of the 'TreeNode' type can be replaced with

Re: [PATCH v4 39/46] qapi/introspect.py: Unify return type of _make_tree()

2020-09-30 Thread Eduardo Habkost
On Wed, Sep 30, 2020 at 12:31:43AM -0400, John Snow wrote: > Returning a *something* or a Tuple of *something* is hard to accurately > type. Let's just always return a tuple for structural consistency. > > Instances of the 'TreeNode' type can be replaced with the slightly more > specific 'Annotate

[PATCH v4 39/46] qapi/introspect.py: Unify return type of _make_tree()

2020-09-29 Thread John Snow
Returning a *something* or a Tuple of *something* is hard to accurately type. Let's just always return a tuple for structural consistency. Instances of the 'TreeNode' type can be replaced with the slightly more specific 'AnnotatedNode' type. Signed-off-by: John Snow --- scripts/qapi/introspect.