Opened 14 years ago

Closed 14 years ago

#1875 closed Bugs (fixed)

Boost.Iostreams warnings with GCC -Wall -W -std=c++98 -pedantic

Reported by: anonymous Owned by: Jonathan Turkanis
Milestone: Component: iostreams
Version: Boost 1.35.0 Severity: Problem
Keywords: Cc:

Description

I'm using Boost.Iostreams on Mac OS X 10.4 with GCC 4.0.1 and the highest Warninglevel -Wall -W -std=c++98. GCC reports warnings for the Iostreams Headers. Even if those aren't real bugs. They should be fixed since every sane programer usually wants to compile without warnings!

boost-1_35/boost/iostreams/chain.hpp:416: warning: base class 'class boost::iostreams::detail::chain_base<boost::iostreams::chain<boost::iostreams::input, char, std::char_traits<char>, std::allocator<char> >, char, std::char_traits<char>, std::allocator<char>, boost::iostreams::input>' should be explicitly initialized in the copy constructor

Change History (4)

comment:1 by anonymous, 14 years ago

boost/iostreams/read.hpp:82: warning: unused parameter ‘t’

comment:2 by anonymous, 14 years ago

boost/iostreams/filter/gzip.hpp:135: warning: unused parameter ‘comment’

comment:3 by Jonathan Turkanis, 14 years ago

Status: newassigned

I can't reproduce any of the warnings, but I've made a change to chain.hpp that I hope will fix the first warning. (See [45781]). Please check to see that the problem is fixed. I'm not sure why the code was written the way it was -- possibly it was to make the library work with VC6.0 or an old version of Borland.

As for the two unused parameter warnings, I take these seriously, but I can't find the unused 't' in the first warnings, and the parameter 'comment' from the second warning does appear to be used. What version of Boost are you using (I know the ticket says 1.35.0, but that seems to be the default value)?

comment:4 by Jonathan Turkanis, 14 years ago

Resolution: fixed
Status: assignedclosed

I'm going to close this, since the first warning is pretty clear, even though I can't reproduce it, and the change to chain.hpp addresses it directly. I believe I have fixed all the unreferenced parameter warnings in response to other tickets.

Note: See TracTickets for help on using tickets.