There are 745 modules to be migrated to using long types.
Start by enabling also attribute(format) on msvcrt APIs (for printf and scanf -like APIs) And continue by migration some modules in programs.
FWI, I've scripted the migration. Between 80 and 90% of the modules can be done automatically (ie fully migrated without warnings); for the remaining modules, again 80 to 90% of the warnings are fixed automatically.
The remaining must be done manually. Regular items to be looked into: - "complex" format strings (multi-line, in static variable, embedded inside macros...) - long/int mismatch (in pointer as argument, in proto vs definition of function...). Here the fix must be decided on a case by case basis. - multi-directories modules (like d3d, msvcrt, atl to name a few). Likely, requires migrating several modules at once.
If you're interested at looking into your favorite module, don't hesitate to go back to me (I can provide the raw automated changes if this can help you).
The plan is to start to migrate programs/*. Then likely dlls/*. The [dlls/programs]/tests/* shall wait for Fabian to finish the gcc11 todo fixes.
A+ --
Eric Pouech (15): include/msvcrt: add attribute((format)) to printf and scanf -like APIs programs/attrib: enable compilation with long types programs/cabarc: enable compilation with long types programs/chcp.com: enable compilation with long types programs/cmd: enable compilation with long types programs/conhost: enable compilation with long types programs/[cw]script: enable compilation with long types programs/dxdiag: enable compilation with long types programs/eject: enable compilation with long types programs/explorer: enable compilation with long types programs/fsutil: enable compilation with long types programs/msiexec: enable compilation with long types programs/net: enable compilation with long types programs/netstat: enable compilation with long types programs/ping: enable compilation with long types
dlls/compobj.dll16/compobj.c | 2 +- dlls/crypt32/sip.c | 2 +- dlls/iphlpapi/iphlpapi_main.c | 2 +- dlls/iphlpapi/tests/iphlpapi.c | 4 +- dlls/msdmo/tests/msdmo.c | 2 +- dlls/mshtml/main.c | 2 +- dlls/oleaut32/oleaut.c | 2 +- dlls/oleaut32/typelib.c | 2 +- dlls/rpcrt4/rpcrt4_main.c | 4 +- dlls/shell32/classes.c | 2 +- dlls/shell32/debughlp.c | 2 +- dlls/shell32/shfldr.h | 2 +- dlls/shlwapi/ordinal.c | 2 +- dlls/typelib.dll16/typelib.c | 2 +- dlls/webservices/writer.c | 4 +- include/msvcrt/corecrt.h | 8 +++ include/msvcrt/crtdbg.h | 2 +- include/msvcrt/stdio.h | 90 ++++++++++++++++++++++------------ programs/attrib/Makefile.in | 1 - programs/attrib/attrib.c | 6 +-- programs/cabarc/Makefile.in | 1 - programs/cabarc/cabarc.c | 2 +- programs/chcp.com/Makefile.in | 1 - programs/chcp.com/main.c | 4 +- programs/cmd/Makefile.in | 1 - programs/cmd/builtins.c | 20 ++++---- programs/cmd/directory.c | 4 +- programs/cmd/wcmdmain.c | 14 +++--- programs/conhost/Makefile.in | 1 - programs/conhost/conhost.c | 18 +++---- programs/conhost/window.c | 10 ++-- programs/cscript/Makefile.in | 2 +- programs/dxdiag/Makefile.in | 1 - programs/dxdiag/information.c | 2 +- programs/dxdiag/output.c | 6 +-- programs/eject/Makefile.in | 1 - programs/eject/eject.c | 6 +-- programs/explorer/Makefile.in | 1 - programs/explorer/appbar.c | 2 +- programs/explorer/desktop.c | 52 ++++++++++---------- programs/explorer/explorer.c | 4 +- programs/explorer/systray.c | 2 +- programs/fsutil/Makefile.in | 1 - programs/fsutil/main.c | 2 +- programs/msiexec/Makefile.in | 1 - programs/msiexec/msiexec.c | 12 ++--- programs/msiexec/service.c | 4 +- programs/net/Makefile.in | 1 - programs/net/net.c | 4 +- programs/netstat/Makefile.in | 1 - programs/netstat/netstat.c | 2 +- programs/ping/Makefile.in | 1 - programs/ping/ping_main.c | 2 +- programs/winetest/main.c | 2 +- programs/wscript/Makefile.in | 1 - programs/wscript/arguments.c | 8 +-- programs/wscript/host.c | 10 ++-- programs/wscript/main.c | 6 +-- 58 files changed, 190 insertions(+), 166 deletions(-)