On Fri, Aug 06, 2021 at 08:29:03AM -0000, wyz2...@163.com wrote:

> I thought that many places in stdlib could be made faster by this 
> (bool is used a lot), maybe this is a major speedup.

I doubt that there are many places in the stdlib where the call to bool 
is the bottleneck, and a micro-optimization of avoiding the function 
call would make it a "major speedup".

If you profile the stdlib modules, do you find any where calls to bool 
make up a major part of the run time cost?


-- 
Steve
_______________________________________________
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/HNV7MLOY6CYORBS7V3Z7DAU365SCRJMP/
Code of Conduct: http://python.org/psf/codeofconduct/

Reply via email to