On 14/05/2024 8:14 am, Roger Pau Monné wrote:
> On Fri, May 10, 2024 at 11:39:59PM +0100, Andrew Cooper wrote:
>> Rename INIT_FEATURE_NAMES to INIT_FEATURE_NAME_TO_VAL as we're about to gain 
>> a
>> inverse mapping of the same thing.
>>
>> Use dict.items() unconditionally.  iteritems() is a marginal perf 
>> optimsiation
>> for Python2 only, and simply not worth the effort on a script this small.
> My understanding is that what used to be iteritems() in Python 2 is
> the behavior of items() in Python 3 (return a generator instead of a
> copy of the dictionary list).

Yes-ish.  They're actually now view() objects following the official
stabilisation of the internal format, which are more-efficient-still in
the common case.

>
>> Signed-off-by: Andrew Cooper <andrew.coop...@citrix.com>
> Reviewed-by: Roger Pau Monné <roger....@citrix.com>

Thanks.

~Andrew

Reply via email to