You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Hello:
Thanks for this piece of software which I have found very helpful.
I use it in one of our projects where we happen to also use the -Wconversion gcc flag. When doing like this, a lot of warning are issued by the compiler. For instance:
In file included from ../../src/main.cpp:38:0:
../../../inc/CRC.h: In instantiation of ‘static CRCType CRC::CalculateRemainder(const void*, size_t, const CRC::Parameters<CRCType, CRCWidth>&, CRCType) [with CRCType = unsigned char; short unsigned int CRCWidth = 8u; size_t = long unsigned int]’:
../../../inc/CRC.h:438:43: required from ‘static CRCType CRC::Calculate(const void*, size_t, const CRC::Parameters<CRCType, CRCWidth>&) [with CRCType = unsigned char; short unsigned int CRCWidth = 8u; size_t = long unsigned int]’
../../src/main.cpp:102:41: required from ‘void CRCBitByBitTest(const char*, size_t, const CRC::Parameters<CRCType, CRCWidth>&, CRCType, const string&) [with CRCType = unsigned char; short unsigned int CRCWidth = 8u; size_t = long unsigned int; std::__cxx11::string = std::__cxx11::basic_string<char>]’
../../src/main.cpp:208:5: required from here
../../../inc/CRC.h:624:23: warning: conversion to ‘unsigned char’ from ‘int’ may alter its value [-Wconversion]
remainder ^= *current++;
~~~~~~~~~~^~~~~~~~~~~~~
Find attached the whole build log and a patch to reproduce the problem.
Steps to reproduce (on Debian Stretch but could work for other distros) :
Hello:
Thanks for this piece of software which I have found very helpful.
I use it in one of our projects where we happen to also use the -Wconversion gcc flag. When doing like this, a lot of warning are issued by the compiler. For instance:
Find attached the whole build log and a patch to reproduce the problem.
Steps to reproduce (on Debian Stretch but could work for other distros) :
build.log
gcc-Wconversion-diff.txt
The text was updated successfully, but these errors were encountered: