
July 22, 2021
1:03 p.m.
On 7/22/21 1:01 AM, Petr Viktorin wrote:
On 21. 07. 21 14:18, Nick Coghlan wrote:
==================== typedef enum { PyLocals_UNDEFINED = -1; PyLocals_DIRECT_REFERENCE = 0, PyLocals_SHALLOW_COPY = 1 } PyLocals_Kind;
PyLocals_Kind PyLocals_GetKind(void); PyLocals_Kind PyFrame_GetLocalsKind(PyFrameObject *); ====================
Please don't put the enum in the stable ABI. If we would add another value and then an older extension would receive it, we'd get undefined behavior.
Probably a stupid question, but wouldn't the same thing happen if we didn't use an enum, added another option later, and on older extension received that newer value? -- ~Ethan~