This is the mail archive of the gcc@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]

Re: Does --enable-clocale=gnu work on Linux/ia64?


Benjamin Kosnik <bkoz@redhat.com> writes:

> > -	  _M_decimal_point = reinterpret_cast<wchar_t>(__nl_langinfo_l(_NL_NUMERIC_DECIMAL_POINT_WC, __cloc));
> > -	  _M_thousands_sep = reinterpret_cast<wchar_t>(__nl_langinfo_l(_NL_NUMERIC_THOUSANDS_SEP_WC,__cloc));
> > +	  long int ch;
> > +	  ch = reinterpret_cast<long int>(__nl_langinfo_l(_NL_NUMERIC_DECIMAL_POINT_WC, __cloc));
> > +	  _M_decimal_point = (wchar_t) ch;
> 
> C++ style casts, like        static_cast<wchar_t>(ch);
> 
> Looks ok to me. Uli?

I don't see why this should be a problem.  The compiler shouldn't warn
about this.  If you use reinterpret_cast you should be allowed to cast
from aa pointer to a narrower integer type.

-- 
---------------.                          ,-.   1325 Chesapeake Terrace
Ulrich Drepper  \    ,-------------------'   \  Sunnyvale, CA 94089 USA
Red Hat          `--' drepper at redhat.com   `------------------------


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