This is the mail archive of the gcc-bugs@gcc.gnu.org mailing list for the GCC project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

[Bug other/43295] zlib: two C++ member functions could be marked const



------- Comment #2 from redi at gcc dot gnu dot org  2010-03-09 10:34 -------
besides which, making it const would allow:

void bork_the_stream(const izstream& i)
{
    ::gzclose(i.fp());
}

which doesn't help anyone.  cppcheck is a very simplistic pattern matcher, in
this case it's wrong IMHO, that it could be const does not mean _should_ be
const.


-- 


http://gcc.gnu.org/bugzilla/show_bug.cgi?id=43295


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]