Boost logo

Boost :

From: Fernando Cacciola (fcacciola_at_[hidden])
Date: 2001-10-30 09:48:42

----- Original Message -----
From: Daryle Walker <darylew_at_[hidden]>
To: Boost <boost_at_[hidden]>
Sent: Friday, October 26, 2001 10:47 PM
Subject: [boost] Quick look at improved_numeric_cast

> I'm looking at the archive at:
> .zip
> that I downloaded this afternoon.
> It looks neat. Let's try to get it to compile....
> 1. You should try using forward slashes instead of back slashes to
> directories in your #includes. DOS/Windows will take either one, but back
> slashes risk getting escape sequences in the file names, which are

> 2. Since I'm not using your compiler, let alone your computer type, the
> #include <windows.h> and #pragma hdrstop are useless to me. (The second
> got me a warning, the first wasn't noted since I have a totally different
> <Windows.h>.)

> 3. Be careful of expressions like
> bool_to_type<::boost::is_integral<N>::value>::typed_value
> Abutting a globally-referenced name next to an opening template bracket is
> bad idea because "<:" is a digraph (for "[")! Make sure to add spacing.
> Remember, digraphs and trigraphs are technically _not_ optional, so some
> compilers don't give an option to ignore them.

> 4. You may want to use BOOST_NESTED_TEMPLATE and other macros to help
> older compilers.
> I can't continue. In "numeric_cast_traits_detail.hpp", my compiler is
> expecting a comma after the BOOST_STATIC_CONSTANT of
> boost::numeric_cast_traits_detail::subranged_int_to_int<T, S>::value. I
> later get an internal error in the same file. Oh well, maybe this code is
> too complex for my compiler (Metrowerks CodeWarrior Pro 5.3/Mac) to


Thanks for all these comments!
I rearranged the code a little based on the line were the error ocurred,
after I guessed what could have been that MCW didn't like.
I hope this made it compile with more compilers than BC5.5.1
For now, I uploaded ONLY the archive ""
Could you check this please?

I haven't applied the changes suggested by Darin Adler, yet, since those are
interface changes -but I agreed with him-
I'll wait for more feedback before I start with the syntatic/semantic


Fernando Cacciola
Sierra s.r.l.

Boost list run by bdawes at, gregod at, cpdaniel at, john at