2018-05-26 11:24 GMT+02:00 Antoine Rozo :
> Dismiss my message, I have read `if "art_wt" not in article`. But in the
> same way, you could have a function to reset a value in your dict if the
> current value evaluates to False.
That won't work, since at other places, I do the same with bools and
s
2018-05-26 11:00 GMT+02:00 Kirill Balunov :
> The main point is to collect more information, since the idea of assignment
> expression will have a huge impact in all aspects of Python programming: how
> you structure your programm, how you write code, how you read code, how you
> parse code... Beca
Michael Lohmann wrote:
class Magic:
magic_number = 42
def __init__(self):
A.magic_number = 0 # As soon as you look too deep into it all the
Magic vanishes
What is A here? Did you mean something else?
--
Greg
___
Pyt
Nick Coghlan wrote:
Aye, while I still don't want comprehensions to implicitly create new
locals in their parent scope, I've come around on the utility of letting
inline assignment targets be implicitly nonlocal references to the
nearest block scope.
What if you're only intending to use it lo
> Everything my idea has to offer really is just reasonable if you don’t have
> single inheritance only
I would like to correct myself immediately on that one: In the Pizza-example
(from yesterday as well) it would be possible to overwrite the default price of
the HawaiianPizza with the mergin
I realized that bypassing kwargs is probably the least important thing of this
idea - so if implemented it definitely had to get a better name. Just look at
the following example:
class Magic:
magic_number = 42
def __init__(self):
A.magic_number = 0 # As soon as
Brendan Barnwell wrote:
If I understand correctly, the essence of your argument seems to be
that you want be able to write a class A, and you want to be able to use
that class EITHER as the top of an inheritance chain (i.e., have it
inherit directly from object) OR in the middle of an inhe
On 26 May 2018 at 04:14, Tim Peters wrote:
> [Peter O'Connor]
> >> ...
> >> We could use given for both the in-loop variable update and the variable
> >> initialization:
> >>smooth_signal = [average given average=(1-decay)*average + decay*x
> >> for x in signa
> If I understand correctly, the essence of your argument seems to be
> that you want be able to write a class A, and you want to be able to use that
> class EITHER as the top of an inheritance chain (i.e., have it inherit
> directly from object) OR in the middle of an inheritance chain (