This is the mail archive of the
gcc-bugs@gcc.gnu.org
mailing list for the GCC project.
[Bug other/43295] zlib: two C++ member functions could be marked const
- From: "redi at gcc dot gnu dot org" <gcc-bugzilla at gcc dot gnu dot org>
- To: gcc-bugs at gcc dot gnu dot org
- Date: 9 Mar 2010 10:34:37 -0000
- Subject: [Bug other/43295] zlib: two C++ member functions could be marked const
- References: <bug-43295-9596@http.gcc.gnu.org/bugzilla/>
- Reply-to: gcc-bugzilla at gcc dot gnu dot org
------- 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