Hi Marti,
I've completed my changes to the LittleCMS sources. I've reviewed and
tested them with the testbed.
http://Noel.ProDigitalSoftware.com/temp/ProposedLittleCMSChanges.zip
With this set of files, derived from the Git trunk as of July 26, you
can now use the C++ compiler and higher warning levels.
I followed this philosophy:
1. Don't alter the external interface (lcms2.h)
2. Make the use of signed and unsigned types consistent to reduce
the hundreds of warnings emitted when -Wall is used with the pickier C++
compiler.
3. Avoid casts if possible.
4. Review all changes and pass all tests in the testbed project.
5. Maintain or improve performance.
If you choose to enable the Visual Studio 2017 C++ compiler and the
highest warning level for your ongoing work, the following may be of
interest:
You may want to specifically disable several of the specific overly
pedantic -Wall warnings by putting the following additional options on
the VS 2017 C++ compiler command line:
/wd4711 /wd4820 /wd4061 /wd4774 /wd4710 /wd4668 /wd4738
The above options specifically quiet the following warnings, which may
not be helpful to you in ongoing development:
warning C4711: function 'xxxxxxxxxxxxxx' selected for automatic inline
expansion
warning C4820: 'xxxxxxxx': 'n' bytes padding added after data member
warning C4061: enumerator 'xxxxxxxxxxxxx' in switch of enum
'yyyyyyyyyyyyy' is not explicitly handled by a case label
warning C4774: '_snprintf' : format string expected in argument 3 is
not a string literal
warning C4710: 'int _snprintf(char *const ,const ::size_t,const char
*const ,...)': function not inlined
warning C4668: '_M_HYBRID_X86_ARM64' is not defined as a preprocessor
macro, replacing with '0' for '#if/#elif'
warning C4738: storing 32-bit float result in memory, possible loss of
performance
After suppressing the above, there is a remaining "unsafe conversion"
warning emitted for cmsxform.c that may indicate a possible real
problem, especially in light of compiling this library for different
systems with different compilers. This is no different than in the code
I started with.
Besides the code compiling cleaner, the testbed project also shows
performance changes for the better in my testing.
-Noel
------------------------------------------------------------------------------
Check out the vibrant tech community on one of the world's most
engaging tech sites, Slashdot.org! http://sdm.link/slashdot
_______________________________________________
Lcms-user mailing list
Lcms-user@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/lcms-user