A RetroSearch Logo

Home - News ( United States | United Kingdom | Italy | Germany ) - Football scores

Search Query:

Showing content from https://mail.python.org/pipermail/python-dev/2018-July/154682.html below:

[Python-Dev] PEP 572 and assert

[Python-Dev] PEP 572 and assert [Python-Dev] PEP 572 and assertBarry Warsaw barry at python.org
Tue Jul 17 14:24:43 EDT 2018
On Jul 17, 2018, at 07:59, Guido van Rossum <guido at python.org> wrote:
> 
> Personally I like Barry's example just fine -- assuming `subdirs` is not used later, this feels like a good use case.

Thanks!  I thought it was cute.  It was just something that occurred to me as I was reviewing some existing code.  The intent wasn’t to use `subdirs` outside of the assert statement, but I’m warm to it because it means I don’t have to do wasted work outside of the assert statement, or repeat myself in the assert message part.

-Barry

-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 833 bytes
Desc: Message signed with OpenPGP
URL: <http://mail.python.org/pipermail/python-dev/attachments/20180717/08325c81/attachment.sig>
More information about the Python-Dev mailing list

RetroSearch is an open source project built by @garambo | Open a GitHub Issue

Search and Browse the WWW like it's 1997 | Search results from DuckDuckGo

HTML: 3.2 | Encoding: UTF-8 | Version: 0.7.4