Planet
navi homePPSaboutscreenshotsdownloaddevelopmentforum

source: downloads/boost_1_34_1/libs/mpl/book/chapter1/binary.hpp @ 29

Last change on this file since 29 was 29, checked in by landauf, 17 years ago

updated boost from 1_33_1 to 1_34_1

File size: 433 bytes
Line 
1//
2// Copyright 2005 David Abrahams and Aleksey Gurtovoy. Distributed
3// under the Boost Software License, Version 1.0. (See accompanying
4// file LICENSE_1_0.txt or copy at
5// http://www.boost.org/LICENSE_1_0.txt)
6//
7#include "boost/mpl/long.hpp"
8#include "boost/mpl/alias.hpp"
9
10template< long n > struct binary
11    : mpl::long_< ( binary< n / 10 >::value << 1 ) + n % 10 >
12{
13};
14
15template<> struct binary<0>
16    : mpl::long_<0>
17{
18};
Note: See TracBrowser for help on using the repository browser.