ANSI C++ fixes, to allow compilation with g++ 3.x.
This commit is contained in:
parent
96665adcce
commit
73f5eec1b7
4 changed files with 2 additions and 16 deletions
|
@ -668,7 +668,7 @@ void FGNewEngine::Do_Prop_Calcs()
|
|||
//cout << "RPM = " << RPM << '\n';
|
||||
//cout << "angular_velocity_SI = " << angular_velocity_SI << '\n';
|
||||
|
||||
prop_power_consumed_SI = Cp * rho_air * pow(FGProp1_RPS,3.0) * pow(prop_diameter,5.0);
|
||||
prop_power_consumed_SI = Cp * rho_air * pow(FGProp1_RPS,3.0f) * pow(float(prop_diameter),5.0f);
|
||||
//cout << "prop HP consumed = " << prop_power_consumed_SI / 745.699 << '\n';
|
||||
if(angular_velocity_SI == 0)
|
||||
prop_torque = 0;
|
||||
|
|
|
@ -225,7 +225,7 @@ void FGTable::Print(void)
|
|||
}
|
||||
cout << endl;
|
||||
}
|
||||
cout.setf(0, ios::floatfield); // reset
|
||||
cout.setf((ios_base::fmtflags)0, ios::floatfield); // reset
|
||||
}
|
||||
|
||||
//%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
|
||||
|
|
|
@ -125,9 +125,7 @@ SG_USING_STD(map);
|
|||
#if !defined (SG_HAVE_NATIVE_SGI_COMPILERS)
|
||||
SG_USING_STD(iostream);
|
||||
#endif
|
||||
#if defined ( macintosh ) || defined ( _MSC_VER )
|
||||
SG_USING_STD(ofstream);
|
||||
#endif
|
||||
|
||||
|
||||
typedef stack :: iterator LIST;
|
||||
|
|
|
@ -381,11 +381,7 @@ ssgBranch *fgAsciiObjLoad( const string& path, FGTileEntry *t,
|
|||
while ( ! in.eof() ) {
|
||||
#endif
|
||||
|
||||
#if defined( macintosh ) || defined( _MSC_VER )
|
||||
in >> ::skipws;
|
||||
#else
|
||||
in >> skipws;
|
||||
#endif
|
||||
|
||||
if ( in.get( c ) && c == '#' ) {
|
||||
// process a comment line
|
||||
|
@ -628,11 +624,7 @@ ssgBranch *fgAsciiObjLoad( const string& path, FGTileEntry *t,
|
|||
|
||||
// read all subsequent numbers until next thing isn't a number
|
||||
while ( true ) {
|
||||
#if defined( macintosh ) || defined( _MSC_VER )
|
||||
in >> ::skipws;
|
||||
#else
|
||||
in >> skipws;
|
||||
#endif
|
||||
|
||||
char c;
|
||||
in.get(c);
|
||||
|
@ -740,11 +732,7 @@ ssgBranch *fgAsciiObjLoad( const string& path, FGTileEntry *t,
|
|||
|
||||
// eat white space before start of while loop so if we are
|
||||
// done with useful input it is noticed before hand.
|
||||
#if defined( macintosh ) || defined( _MSC_VER )
|
||||
in >> ::skipws;
|
||||
#else
|
||||
in >> skipws;
|
||||
#endif
|
||||
}
|
||||
}
|
||||
|
||||
|
|
Loading…
Reference in a new issue