Opened 12 years ago

Closed 12 years ago

#4552 closed Bugs (fixed)

warning: type qualifiers ignored on function return type

Reported by: Roland Bock <rbock@…> Owned by: Robert Ramey
Milestone: Boost 1.45.0 Component: serialization
Version: Boost 1.44.0 Severity: Problem
Keywords: Cc:

Description

Hi,

I get several warnings about const qualifiers for boost::archive and boost::serialization:

boost/archive/basic_archive.hpp:57: warning: type qualifiers ignored on function return type
boost/archive/basic_archive.hpp:93: warning: type qualifiers ignored on function return type
boost/archive/basic_archive.hpp:130: warning: type qualifiers ignored on function return type
boost/archive/basic_archive.hpp:164: warning: type qualifiers ignored on function return type
boost/serialization/collection_size_type.hpp

In all cases, the returned type is a built-in integral type. Thus, the const qualifier is obsolete and should be removed to get rid of the warning.

Thanks and regards,

Roland

Change History (6)

comment:1 by Roland Bock <rbock@…>, 12 years ago

Sorry, missed one:

boost/serialization/item_version_type.hpp:39: warning: type qualifiers ignored on function return type

comment:2 by Robert Ramey, 12 years ago

Resolution: fixed
Status: newclosed

I believe I've fixed this in the trunk. (1.45)

Robert Ramey

comment:3 by Roland Bock <rbock@…>, 12 years ago

Resolution: fixed
Status: closedreopened

Just looked into the trunk: All the reported const qualifiers are still in place.

Roland

PS: The original post failed to contain the line number for boost/serialization/collection_size_type.hpp. It is 40

comment:4 by Robert Ramey, 12 years ago

Resolution: fixed
Status: reopenedclosed

I checked the fix into the trunk

Robert Ramey

comment:5 by christophe.j.henry@…, 12 years ago

Milestone: Boost 1.44.0Boost-1.45.0
Resolution: fixed
Status: closedreopened

I still have that one:

boost/serialization/item_version_type.hpp:39: warning: type qualifiers ignored on function return type

and sure enough, in the trunk header I find: operator const base_type () const

Could this be fixed for 1.45?

comment:6 by Robert Ramey, 12 years ago

Resolution: fixed
Status: reopenedclosed
Note: See TracTickets for help on using tickets.