On 1/10/22 8:18 am, MRAB wrote:
It's OK to INCREF them, provided that you DECREF them when you no longer need them, and remember that if it's a "new reference" you'd need to DECREF it twice.
Which means there would usually be no point in doing the extra INCREF/DECREF. You still need to know whether it's a new reference or not and treat it accordingly. -- Greg -- https://mail.python.org/mailman/listinfo/python-list