[Python-ideas] Re: Possibility to decorate single code line or code block?

2020-12-19 Thread Paul Sokolovsky
Hello, On Sat, 19 Dec 2020 03:52:46 +0100 Marco Sulla wrote: > Maybe it's a crazy idea, but what if we could decorate a single line > of code? That's definitely useful, as a generic programming language concept. My favorite example is from (embedded) C, where I'd like to have per-callsite cont

[Python-ideas] built in to clear terminal

2020-12-19 Thread Christopher Barker
Sorry -- I can't find the thread, but there was a discussion on this list about whether there should be a built in for clearing the terminal screen. I'm was on the fence about it -- but one more data point: One of my beginning Python students just submitted code with this in it: def clear_scree

[Python-ideas] Re: built in to clear terminal

2020-12-19 Thread Steven D'Aprano
Thread is here: https://mail.python.org/archives/list/[email protected]/message/EWQ2BOL3WVZAU2V2MT3HLXN3AEBHANNZ/ I don't think this needs to be a literal built-in, part of the interpreter. I think it could be a library function which is added to builtins on startup, like `help` and `qui

[Python-ideas] Re: built in to clear terminal

2020-12-19 Thread Guido van Rossum
On Sat, Dec 19, 2020 at 7:43 PM Steven D'Aprano wrote: > Thread is here: > > > https://mail.python.org/archives/list/[email protected]/message/EWQ2BOL3WVZAU2V2MT3HLXN3AEBHANNZ/ > > > I don't think this needs to be a literal built-in, part of the > interpreter. I think it could be a library