Stefan Behnel added the comment: I'm fine with PyDict_GetItemOrSetDefault() as well. ---------- _______________________________________ Python tracker <report at bugs.python.org> <http://bugs.python.org/issue17327> _______________________________________