[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: [XEN PATCH for-4.17 v5 16/17] tools/golang/xenlight: Rework gengotypes.py and generation of *.gen.go
- To: Andrew Cooper <Andrew.Cooper3@xxxxxxxxxx>
- From: George Dunlap <George.Dunlap@xxxxxxxxxx>
- Date: Fri, 14 Oct 2022 11:24:15 +0000
- Accept-language: en-US
- Arc-authentication-results: i=1; mx.microsoft.com 1; spf=pass smtp.mailfrom=citrix.com; dmarc=pass action=none header.from=citrix.com; dkim=pass header.d=citrix.com; arc=none
- Arc-message-signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=microsoft.com; s=arcselector9901; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-AntiSpam-MessageData-ChunkCount:X-MS-Exchange-AntiSpam-MessageData-0:X-MS-Exchange-AntiSpam-MessageData-1; bh=YO82JN/k5JwpSbIr+NkjYIYpYUlo64z7IT00WZCFuNo=; b=gc0XmZrC1o1oKzHAQziM7zf6Vl5BiHPWMg2oPI6SjOLZadS0XDKaUA12G/revVOauI+NfraCk9srxRTL4yXKMcBEinMsw0yovOl9BzZ7Pq3xOUDo+bSyA2EgWaADX0lzdfdp9D2NlmOw1vFETxC6HNnwQd8RO/3WLUbfYpQwtH/HbNsmutfwvFSpwfTiS6uPCG9YQCnYRQLWJLFoUBAeq3IcbFM1ON6dg6BoL167nUH2Mi6vjH+p//WLYSfQa2W1AvmPExPRwkZBMFSPBx4KRjHYIUTX7iCkT2tPcxiix2L/8bjAo0Yvm6QCjwqxlAmB+L5jKDx0DDkiDFrtyAa1Og==
- Arc-seal: i=1; a=rsa-sha256; s=arcselector9901; d=microsoft.com; cv=none; b=Ov7NIXuPeD1tu64Ftg3H3O7D9/UsC30pwMiR2wFLPgyaUgOqilbc2UoZ1ooHINW/ouGauDxxh7vqJZb6eLtA40H606VjFtUkOEQNfDW6thb7Vxx5gGbEqvaJrH2Tf9Lbh32gjHp4H1ay44KjhD5de625phvpuxQwYVbqEqrsjAN2v0fdWImRZ2OuzDhy1qxD+OZzylCpYGu0iuVOfp3B3md+ntiWQQPz1GWpZEJeaJNi7/TkWnuDvAp3jB1buZUaSjl2FmX7wJHbVJ8BbzYwwlMMObpBiOSX38C331uEmJEhgXWB3QHbo3DGB76kf4HvsXvIv1l0odbvY3kn/4yiUw==
- Authentication-results: dkim=none (message not signed) header.d=none;dmarc=none action=none header.from=citrix.com;
- Cc: Anthony Perard <anthony.perard@xxxxxxxxxx>, "xen-devel@xxxxxxxxxxxxxxxxxxxx" <xen-devel@xxxxxxxxxxxxxxxxxxxx>, Henry Wang <Henry.Wang@xxxxxxx>, Nick Rosbrook <rosbrookn@xxxxxxxxx>, Wei Liu <wl@xxxxxxx>
- Delivery-date: Fri, 14 Oct 2022 11:24:24 +0000
- Ironport-data: A9a23:awBAGqPD2efrFCHvrR0IlsFynXyQoLVcMsEvi/8bNLWB5Y4Qp3Zem TxOHSzEb+HbITHFz+oGPNy380NS7ZHWmIRgGwtv/CE2QngV8cCYVN3Ecx6qY33LcpebFRg2s JtFNNSecp1oRy+Aq0/8buK8/XIl3KvTStIQZAK81gVZHGeIHw992UILd5cFv7NVbfiF7yKl4 d+rrpaBaAT9i2cvPD8dtqvf8B8x4f6t5T9EswVua/wa4FOGm3crV59OfqvZw1kU4GV3NrXjG 7ucluHREkfxpUpF5gaNy+6jGqEyaueOe1LI0hK6YoD66jBavCs+z60nA/QVbEZTml2hkst4j d5ArvRccy9wVkH3sLlbAkQw/x1WZ/UcouafeCTn66R/8mWdG5fS66Q2ZK0JFdVwFtZfWQlm6 fEeITYRWRGP78reLGWTE7QEamwLdaEHDatH0p1S5Wix4cUOGPgvd57i995AtArcs+gVdRroi 2j1XhI0BPjIS0Un1l76k/vSls/w7pX0W2UwRF54OcPbSoUcpeB8+OGFDTbbRjCFbfp7oR+Zg VCFw3mnKw1GK/mG8QjY/33504cjnQujMG4TPJuR06cyxXG2mCkUAhBQUkanq/6kjEL4Q8hYN 0Ef5isp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QF++dGw=
- List-id: Xen developer discussion <xen-devel.lists.xenproject.org>
- Thread-index: AQHY3wTwBw4XcUEnKkOCwbXR47HHg64MavwAgAFV8IA=
- Thread-topic: [XEN PATCH for-4.17 v5 16/17] tools/golang/xenlight: Rework gengotypes.py and generation of *.gen.go
> On 13 Oct 2022, at 16:00, Andrew Cooper <Andrew.Cooper3@xxxxxxxxxx> wrote:
>
> On 13/10/2022 14:05, Anthony Perard wrote:
>> diff --git a/tools/golang/xenlight/gengotypes.py
>> b/tools/golang/xenlight/gengotypes.py
>> index ac1cf060dd..ff4c2ad216 100644
>> --- a/tools/golang/xenlight/gengotypes.py
>> +++ b/tools/golang/xenlight/gengotypes.py
>> @@ -723,7 +723,13 @@ def xenlight_golang_fmt_name(name, exported = True):
>> return words[0] + ''.join(x.title() for x in words[1:])
>>
>> if __name__ == '__main__':
>> + if len(sys.argv) != 4:
>> + print("Usage: gengotypes.py <idl> <types.gen.go> <helpers.gen.go>",
>> file=sys.stderr)
>
> This breaks with Py2.7. Needs a
>
> from __future__ import print_function
>
> inserting at the top.
Out of curiosity, did you notice this by inspection, or because you
specifically tested Python 2.7, or because a system you were using is still
actually using Python 2.7?
-George
Attachment:
signature.asc
Description: Message signed with OpenPGP
|