Re: Python type annotations

2024-02-29 Thread dima . pasechnik
On Thu, Feb 29, 2024 at 05:16:29PM +0100, Kévin Le Gouguec wrote: > (Hi! Apologies for the drive-by comments, hopefully they won't be > complete noise. Butting in hoping to clarify things at best, stand > corrected at worst) > > Bruno Haible writes: > > >> Python has added a lot of

Re: Python != None

2024-02-25 Thread Dima Pasechnik
On Sun, Feb 25, 2024 at 11:29:51AM -0800, Collin Funk wrote: > On 2/25/24 3:57 AM, Bruno Haible wrote: > > The style warnings about "!= None" in pycodestyle and/or pylint are > > relativized by this warning in Python itself: > > > > >>> '' != None > > True > > >>> '' is not None > > :1:

Re: gnulib-tool.py: Follow gnulib-tool changes, part 27.

2024-02-24 Thread Dima Pasechnik
Hi Bruno, The pythonic way is mode is not None rather than mode != None (the reason is None is an object) Just in case, Dima On 24 February 2024 23:25:51 GMT, Bruno Haible wrote: >Hi Collin, > >> > I.e. you meant to write >> > mode != None >> > not >> > modules != None >> > ?