Message291542
| Author |
vstinner |
| Recipients |
eric.snow, louielu, ncoghlan, serhiy.storchaka, vstinner |
| Date |
2017年04月12日.10:10:17 |
| SpamBayes Score |
-1.0 |
| Marked as misclassified |
Yes |
| Message-id |
<1491991817.23.0.0672526348149.issue29881@psf.upfronthosting.co.za> |
| In-reply-to |
| Content |
I dislike _Py_SET_FINALIZED and _Py_SET_ONCE name.
I prefer to mention an "initialization" because it's a common pattern in programming and it is known that it only requires to be done once.
_PY_ONCEVAR_INIT() macro is unusual: it only evaluate the second parameter parameter, a C expression, if the variable is not initialized yet.
Py_SETREF() is different because it always evaluates its second argument, and in most cases, the second argument is an existing variable and not an expression. |
|