bugpng++, a C++ wrapper for libpng - Bugs: bug #63206, compiler warnings: bitwise...

 
 

bug #63206: compiler warnings: bitwise operation between different enumeration types ('png::color_type' and 'png::color_mask') is de

Submitter:  None
Submitted:  Thu 13 Oct 2022 07:00:10 AM UTC
   
 
Category:  None Severity:  3 - Normal
Item Group:  None Status:  Need Info
Privacy:  Public Assigned to:  None
Open/Closed:  Open
* Mandatory Fields

Add a New Comment Rich Markup
   

Sat 15 Oct 2022 07:52:51 PM UTC, comment #1: 

I'm sure you can also send in a patch to fix it?..

Alexander Shulgin <alexshulgin>
Group administrator
Thu 13 Oct 2022 07:00:10 AM UTC, original submission:  

clang-14 prints these warnings when -std=c++20 is supplied:

In file included from /usr/local/include/png++/png.hpp:59:
/usr/local/include/png++/convert_color_space.hpp:132:55: warning: bitwise operation between different enumeration types ('png::color_type' and 'png::color_mask') is deprecated [-Wdeprecated-enum-enum-conversion]
                bool src_alpha = (io.get_color_type() & color_mask_alpha);
                                  ~~~~~~~~~~~~~~~~~~~ ^ ~~~~~~~~~~~~~~~~
In file included from /usr/local/include/png++/png.hpp:59:
/usr/local/include/png++/convert_color_space.hpp:134:59: warning: bitwise operation between different enumeration types ('png::color_type' and 'png::color_mask') is deprecated [-Wdeprecated-enum-enum-conversion]
                bool dst_alpha = traits::get_color_type() & color_mask_alpha;
                                 ~~~~~~~~~~~~~~~~~~~~~~~~ ^ ~~~~~~~~~~~~~~~~
/usr/local/include/png++/convert_color_space.hpp:201:57: warning: bitwise operation between different enumeration types ('png::color_type' and 'png::color_mask') is deprecated [-Wdeprecated-enum-enum-conversion]
                bool dst_rgb = traits::get_color_type() & color_mask_rgb;
                               ~~~~~~~~~~~~~~~~~~~~~~~~ ^ ~~~~~~~~~~~~~~

png++-0.2.10
OS: FreeBSD 13.1 STABLE

Anonymous

 

(Note: upload size limit is set to 16384 kB, after insertion of the required escape characters.)

Attach Files:
   
   
Comment:
   

No files currently attached

 

Depends on the following items: None found

Items that depend on this one: None found

 

Carbon-Copy List
  • -email is unavailable- added by alexshulgin (Posted a comment)
  •  

    There are 0 votes so far. Votes easily highlight which items people would like to see resolved in priority, independently of the priority of the item set by tracker managers.

    Only logged-in users can vote.

     

    Follows 1 latest change.

    Date Changed by Updated Field Previous Value => Replaced by
    2022-10-15 alexshulgin StatusNone Need Info

    Back to the top

    Powered by Savane 3.12.
    Corresponding source code