1
0
mirror of https://git.dev.opencascade.org/repos/occt.git synced 2025-08-04 13:13:25 +03:00

0023947: Eliminate trivial compiler warnings in MSVC++ with warning level 4

Fix first subset of warnings (about 100)
- while(1) and similar constructs replaced by for(;;)
- some uninitialized variables corrected
Got rid of Warning C4189: local variable is initialised but not referenced
Corrected mistakes after getting rid of C4189 compiler warning
Corrected some mistakes that led to compiling errors
Fixed test case because of improvement message - removed unnecessary TODO.
Small fix: tabs have been replaced with whitespaces.
Added TODO for Windows platform
removed last TODO
Corrected mistakes, returned some #ifdef DEB code, fixed test case .
Restoring a few places which have been modified too much
Small grammar fix
Deleted unnecessary puts in bugs/end
This commit is contained in:
omy
2013-07-12 12:37:38 +04:00
parent a8195d65ba
commit 302f96fb0d
189 changed files with 455 additions and 1010 deletions

View File

@@ -893,7 +893,7 @@ gp_Pnt DefineDU(const Handle(IntPatch_ALine)& aline,
gp_Pnt P1 = aline->Value(U), P2, P3;
gp_Vec V13, V12, V23;
Standard_Real dU = DU/2.0, curvDef, angDef, m1, m2, m3;
do{ //According to class TangentialDeflection from GCPnts
for(;;) { //According to class TangentialDeflection from GCPnts
P2=aline->Value(U+dU); P3=aline->Value(U+DU);
V13 = P3.XYZ().Subtracted(P1.XYZ()); m1 = V13.Magnitude();
V12 = P2.XYZ().Subtracted(P1.XYZ()); m2 = V12.Magnitude();
@@ -903,7 +903,7 @@ gp_Pnt DefineDU(const Handle(IntPatch_ALine)& aline,
angDef = Abs(V13.Angle(V23));
if(curvDef < CurvDef && angDef < AngDef) break;
DU = dU; dU /= 2.0;
}while(1);
}
return P3;
}
//=======================================================================

View File

@@ -149,7 +149,6 @@ void IntPatch_PrmPrmIntersection::Perform (const Handle(Adaptor3d_HSurface)&
done = Standard_True;
SLin.Clear();
Standard_Real Deflection2 = Deflection*Deflection;
Standard_Integer nbLigSec = Interference.NbSectionLines();
Standard_Integer nbTanZon = Interference.NbTangentZones();
@@ -1326,12 +1325,10 @@ void IntPatch_PrmPrmIntersection::Perform (const Handle(Adaptor3d_HSurface)&
if(U2<UminLig2) UminLig2=U2;
if(V2<VminLig2) VminLig2=V2;
}
Standard_Real Deflection2 = Deflection*Deflection;
Standard_Real SeuildPointLigne = 15.0 * Increment * Increment;
Standard_Integer NbPntOn2SOnLine = 0, NbLigCalculee = 0, ver;
Standard_Integer NbLigCalculee = 0, ver;
Standard_Real pu1,pu2,pv1,pv2, dminiPointLigne;
Standard_Boolean HasStartPoint,RejetLigne;
IntSurf_PntOn2S StartPOn2S;
@@ -1896,12 +1893,11 @@ void IntPatch_PrmPrmIntersection::Perform (const Handle(Adaptor3d_HSurface)& Sur
return;
}
Standard_Real Deflection2 = Deflection*Deflection;
Standard_Integer nbLigSec = Interference.NbSectionLines();
Standard_Integer nbTanZon = Interference.NbTangentZones();
Standard_Real SeuildPointLigne = 15.0 * Increment * Increment;
Standard_Integer NbPntOn2SOnLine = 0, NbLigCalculee = 0, ver;
Standard_Integer NbLigCalculee = 0, ver;
Standard_Real U1,U2,V1,V2, pu1,pu2,pv1,pv2, incidence, dminiPointLigne;
Standard_Boolean HasStartPoint,RejetLigne;
IntSurf_PntOn2S StartPOn2S;
@@ -2489,7 +2485,6 @@ void IntPatch_PrmPrmIntersection::Perform (const Handle(Adaptor3d_HSurface)& Sur
empt = Standard_True;
done = Standard_True;
SLin.Clear();
Standard_Real Deflection2 = Deflection*Deflection;
Standard_Integer NbLigCalculee = 0;
Standard_Real U1,U2,V1,V2;