blob: 39213863e7f3d35dcba22bd2eba29cb4d2174903 [file] [log] [blame]
Brian Silvermanfb294a52018-08-04 23:37:57 -07001//
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};