mirror of
https://github.com/swift-project/pilotclient.git
synced 2026-04-21 04:45:31 +08:00
[g2clib] Fix warning about conversion from double to float
This commit is contained in:
@@ -60,17 +60,17 @@ void rdieee(g2int *rieee,g2float *a,g2int num)
|
||||
|
||||
if ( (iexp > 0) && (iexp < 255) ) {
|
||||
temp=(g2float)int_power(2.0,(iexp-127));
|
||||
a[j]=sign*temp*(1.0+(two23*(g2float)imant));
|
||||
a[j]=sign*temp*(1.0f+(two23*(g2float)imant));
|
||||
}
|
||||
else if ( iexp == 0 ) {
|
||||
if ( imant != 0 )
|
||||
a[j]=sign*two126*two23*(g2float)imant;
|
||||
else
|
||||
a[j]=sign*0.0;
|
||||
a[j]=sign*0.0f;
|
||||
|
||||
}
|
||||
else if ( iexp == 255 )
|
||||
a[j]=sign*(1E+37);
|
||||
a[j]=sign*(1E+37f);
|
||||
|
||||
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user