bpo-38321: Fix PyCStructUnionType_update_stgdict() warning (GH-16492) · python/cpython@c9a413e (original) (raw)
Navigation Menu
- GitHub Copilot Write better code with AI
- GitHub Models New Manage and compare prompts
- GitHub Advanced Security Find and fix vulnerabilities
- Actions Automate any workflow
- Codespaces Instant dev environments
- Issues Plan and track work
- Code Review Manage code changes
- Discussions Collaborate outside of code
- Code Search Find more, search less
- Explore
- Pricing
Provide feedback
Saved searches
Use saved searches to filter your results more quickly
Appearance settings
Commit c9a413e
authored and
committed
bpo-38321: Fix PyCStructUnionType_update_stgdict() warning (GH-16492)
bpo-22273, bpo-38321: Fix following warning: modules\_ctypes\stgdict.c(704): warning C4244: 'initializing': conversion from 'Py_ssize_t' to 'int', possible loss of data
File tree
1 file changed
lines changed
1 file changed
lines changed
Lines changed: 1 addition & 1 deletion
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -701,7 +701,7 @@ PyCStructUnionType_update_stgdict(PyObject *type, PyObject *fields, int isStruct | ||
701 | 701 | assert(actual_type_index <= MAX_ELEMENTS); |
702 | 702 | } |
703 | 703 | else { |
704 | -int length = dict->length; | |
704 | +Py_ssize_t length = dict->length; | |
705 | 705 | StgDictObject *edict; |
706 | 706 | |
707 | 707 | edict = PyType_stgdict(dict->proto); |