1 #typedef DyDouble double
2 #typedef DyInt64 int
3 DyDouble GetMaxPrecision(DyDouble db)
4 {
5 assert( sizeof(DyDouble ) == sizeof( DyInt64 ) );
6 DyInt64 exp = ((*((DyInt64*)& db) >>52) & 0x7ff) - 32;
7 if( exp <=0 ) return 1e-299;
8 exp = expDelta << 52;
9 DyDouble reErr = *((DyDouble*)&exp );
10 return reErr;
11 }