• Home
  • Line#
  • Scopes#
  • Navigate#
  • Raw
  • Download
1 // Copyright Abel Sinkovics (abel@sinkovics.hu)  2012.
2 // Distributed under the Boost Software License, Version 1.0.
3 //    (See accompanying file LICENSE_1_0.txt or copy at
4 //          http://www.boost.org/LICENSE_1_0.txt)
5 
6 #include <example_in_haskell.hpp>
7 
8 #include <iostream>
9 
main()10 int main()
11 {
12   using boost::mpl::int_;
13 
14   std::cout
15     << "fib 6 = " << fib::apply<int_<6> >::type::value << std::endl
16     << "fact 4 = " << fact::apply<int_<4> >::type::value << std::endl
17     << "times4 3 = " << times4::apply<int_<3> >::type::value << std::endl
18     << "times11 2 = " << times11::apply<int_<2> >::type::value << std::endl;
19 }
20 
21