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 c++/70106] [4.9/5 Regression][C++11 or above] adding parenthesis [cerr << (var)] cause error: invalid static_cast from type 'const size_t {aka const long unsigned int}' to type 'size_t& {aka long unsigned int&}'


https://gcc.gnu.org/bugzilla/show_bug.cgi?id=70106

Marek Polacek <mpolacek at gcc dot gnu.org> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
                 CC|                            |mpolacek at gcc dot gnu.org
            Summary|[4.9/5/6 Regression][C++11  |[4.9/5 Regression][C++11 or
                   |or above] adding            |above] adding parenthesis
                   |parenthesis [cerr << (var)] |[cerr << (var)] cause
                   |cause error: invalid        |error: invalid static_cast
                   |static_cast from type       |from type 'const size_t
                   |'const size_t {aka const    |{aka const long unsigned
                   |long unsigned int}' to type |int}' to type 'size_t& {aka
                   |'size_t& {aka long unsigned |long unsigned int&}'
                   |int&}'                      |

--- Comment #6 from Marek Polacek <mpolacek at gcc dot gnu.org> ---
Fixed on the trunk so far.

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