Benjamin Peterson <[EMAIL PROTECTED]> added the comment: The patch mostly looks good. However, all the w[-1] logic looks rather verbose to me since its main use case in testing will be making sure *one* warning happened. Returning a list adds the extra step of checking the length and then indexing it for the warning validation. I'm not completely suggesting that you bring back the smart list, but maybe an option on catch_warning to just yield the WarningMessage on __enter__.
---------- keywords: -needs review nosy: +benjamin.peterson _______________________________________ Python tracker <[EMAIL PROTECTED]> <http://bugs.python.org/issue3781> _______________________________________ _______________________________________________ Python-bugs-list mailing list Unsubscribe: http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com