Message218778
#17853 was in the context of metaclasses. Even so, I am puzzled by the opening statement there that
from enum import Enum # I added this as necessary
class Season(Enum):
SPRING = Season()
"works beautifully" at top level as it indeed raises
NameError: name 'Season' is not defined
My point here is that changing the output of
n=1
def f(n=2):
class A: n=n
return A
print(f().n)
from 1, as it has been from the beginning (except for the print change) to 2, which I believe is implied in the request, is not the sort of syntax change we do. Hence I think this should be closed. |
|
Date |
User |
Action |
Args |
2014-05-19 02:58:18 | terry.reedy | set | recipients:
+ terry.reedy, arigo, ethan.furman |
2014-05-19 02:58:18 | terry.reedy | set | messageid: <1400468298.8.0.554331283587.issue19979@psf.upfronthosting.co.za> |
2014-05-19 02:58:18 | terry.reedy | link | issue19979 messages |
2014-05-19 02:58:17 | terry.reedy | create | |
|