Yes, unless you actually argue that technically there is no definite C standard and everyone just randomly agrees (of course there is a C++ one and the optional complex.h in C).[1]
In my personal opinion: Can we please drop these lines of arguments? I honestly doubt anyone here can suggest serious alternative interpretations for anything relevant…
Yes, a proper standard should be precise enough that it doesn’t need the reader to do this type of work. But, the PEP is very old and the truth is it isn’t written like a “proper standard”.
That may be very frustrating but while it is a good argument to want to disregard it; it isn’t a reason for it not being an API break to do so.
And to be clear I don’t think it ever was a reason for that: the reason, as noted, was that there is no API break because it was deemed unimplemented (and that happens to be incorrect).
But it still leaves everything open
and Python has completely free choice here: Use Zd to ensure that the buffer protocol has one obvious way to spell complex numbers. Or choose D because it is nice if the struct module long-term agrees with the buffer protocol!
EDIT: Let me add a poll for the heck of it:
- Use
Zdto avoid two spellings. - Use
Dfor long-termstruct-buffer protocol alignment - I don’t care
The biggest – not even relevant – “deviation” I have ever seen myself is
cuda::std::complexhaving a larger alignment requirement. ↩︎