Ticket #6280: main.cpp

File main.cpp, 272 bytes (added by Simeon Maxein <smaxein@…>, 11 years ago)

Small test program

Line 
1#include <iostream>
2#include <cmath>
3#include <boost/cast.hpp>
4#include <boost/integer.hpp>
5
6using namespace std;
7int main() {
8 try {
9 cout << boost::numeric_cast<int64_t>((float)ldexp(-1,63));
10 } catch(boost::bad_numeric_cast &e) {
11 cout << e.what();
12 }
13}