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++/25845] want optional warning for non-constant declarations that could be constant



------- Comment #11 from gdr at cs dot tamu dot edu  2006-01-18 20:30 -------
Subject: Re:  want optional warning for non-constant declarations that could be
constant

"sigra at home dot se" <gcc-bugzilla@gcc.gnu.org> writes:

|  std::cout << static_cast<unsigned short>(t) << std::endl;
| }
| 
| If "static_cast<const unsigned short>" would work, the compiler should warn.

given call-by-value, you must be joking.

-- Gaby


-- 


http://gcc.gnu.org/bugzilla/show_bug.cgi?id=25845


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