View Single Post
Old 11-03-2015, 09:23 AM   #137
KevinH
Sigil Developer
KevinH ought to be getting tired of karma fortunes by now.KevinH ought to be getting tired of karma fortunes by now.KevinH ought to be getting tired of karma fortunes by now.KevinH ought to be getting tired of karma fortunes by now.KevinH ought to be getting tired of karma fortunes by now.KevinH ought to be getting tired of karma fortunes by now.KevinH ought to be getting tired of karma fortunes by now.KevinH ought to be getting tired of karma fortunes by now.KevinH ought to be getting tired of karma fortunes by now.KevinH ought to be getting tired of karma fortunes by now.KevinH ought to be getting tired of karma fortunes by now.
 
Posts: 8,544
Karma: 5703586
Join Date: Nov 2009
Device: many
Hi,

Most of the warnings I see not in the 3rdparty section of the source, are related to:

Code:
 sizet n = length(of something);
 for (int i=0; i < n; i++) {
    blah;
}

or

int n = length(of something);
for (uint i = 0; i <n; i++) {
   blah;
}
where the only reason the uint is used to is try to get around warnigns from other compilers that used to complain in the reverse direction because the length of some objects may be size_t, int, unsigned int depending on platform and compiler used.

No n will be big enough for this to be an issue of overflow of the non-negative range of values of an int i and adding casts just make the code messy.

None of these are in any way real issues.

The only other warning type in your file is reorder warning as it does not like constructor member initialization lists to be in a different order than the order they are declared in the header for that class. AFAIK, none of these are bugs either. In the C++ spec, the order of initialization in the constructor has nothing to do with the order that members of a class are constructed, destructed, or initialized as that is solely determined by the order of their declaration in the header. So this is a warning about nothing, other than understand the C++ spec on the order of member initialization.

The only other warning type in your list is a unused variable warning that again is there becase of other code that is ifdef'd out at the moment but kept around. So nothing to see here either.

Nothing to worry about here.

Thanks,

KevinH

ps. I have just pushed changes to Sigil master to hopefully prevent these warnings. If you do another clean build any time soon please let me know if you see anything warningwize in Sigil.

Thanks!

Kevin

Quote:
Originally Posted by gbm View Post
I just did a new build of Sigil--Linix Mint 17.2--and had a lot of:
Code:
warning: comparison between signed and unsigned integer expressions [-Wsign-compare]
Are they expected?
The build seems to work ok.

bernie

Last edited by KevinH; 11-04-2015 at 09:02 AM. Reason: added ps to say pushed warning removal changes
KevinH is offline