gh-93421: Update sqlite3 cursor.rowcount after SQLITE_DONE by erlend-aasland · Pull Request #93526 · python/cpython
rowcount's type should also be changed.
Otherwise on 32-bit big-endian platform, it will always be 0.
-{"rowcount", T_LONG, offsetof(pysqlite_Cursor, rowcount), READONLY}, +{"rowcount", T_LONGLONG, offsetof(pysqlite_Cursor, rowcount), READONLY},
lastrowid's type is T_OBJECT, an int object is generated even if the user doesn't access it. we can keep it as integer type. But if access it multiple times, it will be slower.
Of course, this is another issue.