[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: [Qemu-devel] [Qemu-block] [RFC 04/10] python: futurize -f lib2to3.fi
From: |
Stefan Hajnoczi |
Subject: |
Re: [Qemu-devel] [Qemu-block] [RFC 04/10] python: futurize -f lib2to3.fixes.fix_has_key |
Date: |
Mon, 14 May 2018 15:27:41 +0100 |
User-agent: |
Mutt/1.9.5 (2018-04-13) |
On Fri, May 11, 2018 at 07:20:46PM -0300, Eduardo Habkost wrote:
> Change "dict.has_key(key)" to "key in dict"
>
> This is necessary for Python 3 compatibility.
>
> Done using:
>
> $ py=$( (g grep -l -E '^#!.*python';find -name '*.py' -printf '%P\n';) | \
> sort -u | grep -v README.sh4)
> $ futurize -w -f lib2to3.fixes.fix_has_key $py
>
> Signed-off-by: Eduardo Habkost <address@hidden>
> ---
> scripts/qmp/qmp | 4 ++--
> scripts/qmp/qmp-shell | 2 +-
> scripts/qmp/qom-fuse | 2 +-
> scripts/qmp/qom-get | 2 +-
> scripts/qmp/qom-list | 2 +-
> scripts/qmp/qom-set | 2 +-
> scripts/qmp/qom-tree | 2 +-
> tests/qemu-iotests/093 | 2 +-
> tests/qemu-iotests/096 | 4 ++--
> tests/qemu-iotests/136 | 2 +-
> 10 files changed, 12 insertions(+), 12 deletions(-)
Reviewed-by: Stefan Hajnoczi <address@hidden>
signature.asc
Description: PGP signature
- [Qemu-devel] [RFC 00/10] [TESTING NEEDED] python: futurize --stage1 (Python 3 compatibility), Eduardo Habkost, 2018/05/11
- [Qemu-devel] [RFC 02/10] python: futurize -f libfuturize.fixes.fix_absolute_import, Eduardo Habkost, 2018/05/11
- [Qemu-devel] [RFC 03/10] python: futurize -f libfuturize.fixes.fix_next_call, Eduardo Habkost, 2018/05/11
- [Qemu-devel] [RFC 01/10] python: futurize -f libfuturize.fixes.fix_print_with_import, Eduardo Habkost, 2018/05/11
- [Qemu-devel] [RFC 04/10] python: futurize -f lib2to3.fixes.fix_has_key, Eduardo Habkost, 2018/05/11
- [Qemu-devel] [RFC 05/10] python: futurize -f lib2to3.fixes.fix_standarderror, Eduardo Habkost, 2018/05/11
- [Qemu-devel] [RFC 06/10] python: futurize -f lib2to3.fixes.fix_reduce, Eduardo Habkost, 2018/05/11
- [Qemu-devel] [RFC 07/10] python: futurize -f lib2to3.fixes.fix_tuple_params, Eduardo Habkost, 2018/05/11
- [Qemu-devel] [RFC 08/10] python: futurize -f lib2to3.fixes.fix_renames, Eduardo Habkost, 2018/05/11
- [Qemu-devel] [RFC 09/10] python: futurize -f lib2to3.fixes.fix_except, Eduardo Habkost, 2018/05/11