Well. How can I go beyond why constant was invented in the first place? As far 
as I can understand by my limited knowledge that *sometimes* constants can be 
useful, sometimes they are terrible. The main reason constant was invented was 
to provide an additional support to programmers so that they don't make a 
program unstable.  And there are code that really have this problem. Python can 
be "Consenting Adults" language but so are others they just don't claim it. 
Programming is programming, it depends on the user and author what they'll 
choose to do "enforcing" or "consenting adults". And I must confess I don't 
like type checking in this context because Python should itself help us point 
out these relatively small but extremely important bugs related to constants 
(or Final). And constants doesn't make code fast. To avoid decreasing current 
performance, I propose to add new OP code and new AST node for constants so 
that they don't mingle with variables. And all constant assignment check
 ing should be done at runtime not compile time. I hope this actually answers 
all of the questions coming up till now.
_______________________________________________
Python-ideas mailing list -- python-ideas@python.org
To unsubscribe send an email to python-ideas-le...@python.org
https://mail.python.org/mailman3/lists/python-ideas.python.org/
Message archived at 
https://mail.python.org/archives/list/python-ideas@python.org/message/7ZLY3PBGBUC3RGIFWEK5ZZTFU573N3NH/
Code of Conduct: http://python.org/psf/codeofconduct/

Reply via email to