On Mon, Nov 27, 2017 at 9:28 PM, Ivan Pozdeev via Python-ideas <
python-ideas@python.org> wrote:
> On 28.11.2017 5:19, Chris Angelico wrote:
>
> Actually, Python does have a way of disabling assertions (the -O
>> flag), so they should be treated the same way they are in C.
>> Assertions should
On Sun, Dec 3, 2017 at 6:06 PM, Chris Barker wrote:
> In fact, it's striking me that there may well be classes that are defining
> the comparison magic methods not because they want the objects to "work"
> with the comparison operators, but because that want them to work
Care would have to be taken in the grammar to avoid syntactic ambiguity.
For example:
x = 1
def not(x):
...
if not - x: # Is this 'not' the keyword or the identifier? not (-x), or not
minus x?
...
Nathan
On Sun, May 13, 2018 at 2:20 PM Guido van Rossum wrote:
> As
On Wed, Apr 11, 2018 at 1:49 PM, Brendan Barnwell
wrote:
> On 2018-04-11 05:23, Clint Hepner wrote:
>
>> I find the assignments make it difficult to pick out what the final
>> expression looks like.
>>
>
> I strongly agree with this, and for me I think this is
On Sat, Apr 14, 2018 at 11:54 PM, Chris Angelico wrote:
> On Sun, Apr 15, 2018 at 1:08 PM, Nick Coghlan wrote:
> > === Target first, 'from' keyword ===
> >
> > while (value from read_next_item()) is not None: # New
> > ...
> >
> > Pros:
> >
> >
On Sun, Mar 4, 2018 at 11:04 PM, Chris Angelico wrote:
> On Mon, Mar 5, 2018 at 2:49 PM, Mike Miller
> wrote:
> > Yes, thanks:
> >
> > [ f(y), g(y) for x, h(x) as y in things ]
> >
> >
> > Dyslexics untie!
>
> :)
>
> Hmm. The trouble here is that
On Sat, Dec 29, 2018 at 12:30 AM Alexander Heger wrote:
> for regular strings one can write
>
> "aaa" + "bbb"
>
> which also works for f-strings, r-strings, etc.; in regular expressions,
> there is, e.g., parameter counting and references to numbered matches. How
> would that be dealt with in a
On Thu, Mar 21, 2019 at 9:17 AM Serhiy Storchaka
wrote:
> 21.03.19 14:51, Chris Angelico пише:
> > ... then, in the interests of productive discussion, could you please
> > explain? What is it about dict addition that makes it harder to
> > understand than other addition?
>
> Currently the +
On Sat, Apr 25, 2020 at 10:41 AM Steven D'Aprano
wrote:
> On Thu, Apr 23, 2020 at 09:10:16PM -0400, Nathan Schneider wrote:
>
> > How, for example, to collate lines from 3 potentially large files while
> > ensuring they match in length (without an external dependency)? The best
On Thu, Apr 23, 2020 at 3:50 PM Eric Fahlgren
wrote:
> On Wed, Apr 22, 2020 at 12:23 PM David Mertz wrote:
>
>> On Wed, Apr 22, 2020, 4:24 AM Antoine Pitrou
>>
>>> But, as far as I'm concerned, the number of times where I took
>>> advantage of zip()'s current acceptance of heteregenously-sized
On Sun, May 17, 2020 at 6:14 AM Rhodri James wrote:
> On 16/05/2020 17:14, Guido van Rossum wrote:
> > On Sat, May 16, 2020 at 1:26 AM Steven D'Aprano
> wrote:
> >
> >>> * zip(strict=True) +1
> >>> * zip(mode='strict') -0
> >>> * itertools.zip_strict() -0.5
> >>> * zip.strict()
On Sun, May 17, 2020 at 1:32 PM David Mertz wrote:
> On Sun, May 17, 2020 at 12:22 PM Nathan Schneider
> wrote:
>
>> Let me attempt a metaphor, which won't be perfect but may help:
>>
>> The safety one gets from strictness is a bit like driving a
12 matches
Mail list logo