mirror of
https://git.dev.opencascade.org/repos/occt.git
synced 2025-09-03 14:10:33 +03:00
0024510: Remove unused local variables
When warnings are enabled, compilers report lots of occurrences of unused local variables, which makes it harder to find other meaningful warnings. This commit does not fix all unused local variables. Fix new type conversion warning Code cleaned to avoid MSVC compiler warnings on unused function arguments. Several useless pieces of code are removed. Changes in IntTools_EdgeFace.cxx, Blend_Walking_1.gxx, Bnd_BoundSortBox.cxx, ProjLib_ProjectedCurve.cxx are reverted (separated to specific issue for more in-depth analysis).
This commit is contained in:
@@ -531,8 +531,8 @@ void MAT2d_Circuit::InsertCorner (TColGeom2d_SequenceOfGeometry& Line) const
|
||||
if (AffichCircuit) {
|
||||
if (Insert) {
|
||||
Curve = Handle(Geom2d_TrimmedCurve)::DownCast(Line.Value(isuiv));
|
||||
gp_Pnt2d P = Curve->StartPoint();
|
||||
#ifdef DRAW
|
||||
gp_Pnt2d P = Curve->StartPoint();
|
||||
Handle(Draw_Marker2D) dr = new Draw_Marker2D(P,Draw_Plus,Draw_vert);
|
||||
dout << dr;
|
||||
dout.Flush();
|
||||
@@ -798,22 +798,19 @@ static Standard_Boolean IsSharpCorner (const Handle(Geom2d_Geometry)& Geom1,
|
||||
#ifdef DEB
|
||||
static Standard_Boolean Affich = 0;
|
||||
if (Affich) {
|
||||
#ifdef DRAW
|
||||
Standard_Real DU1 = (OC1.LastParameter() - OC1.FirstParameter())/9.;
|
||||
Standard_Real DU2 = (OC2.LastParameter() - OC2.FirstParameter())/9.;
|
||||
for (Standard_Integer ki = 0; ki <= 9; ki++) {
|
||||
gp_Pnt2d P1 = OC1.Value(OC1.FirstParameter()+ki*DU1);
|
||||
gp_Pnt2d P2 = OC2.Value(OC2.FirstParameter()+ki*DU2);
|
||||
#ifdef DRAW
|
||||
Handle(Draw_Marker2D) dr1 = new Draw_Marker2D(P1,Draw_Plus,Draw_vert);
|
||||
Handle(Draw_Marker2D) dr2 = new Draw_Marker2D(P2,Draw_Plus,Draw_rouge);
|
||||
dout << dr1;
|
||||
dout << dr2;
|
||||
}
|
||||
dout.Flush();
|
||||
#else
|
||||
}
|
||||
#endif
|
||||
|
||||
}
|
||||
#endif
|
||||
|
||||
|
@@ -406,8 +406,7 @@ void MAT2d_Tool2d::TrimBisec ( Bisector_Bisec& B1,
|
||||
|
||||
//gp_Vec2d Tan1,Tan2;
|
||||
gp_Pnt2d Ori; //PEdge;
|
||||
Standard_Integer IPrec,INext;
|
||||
IPrec = (IndexEdge == 1) ? theCircuit->NumberOfItems() : (IndexEdge - 1);
|
||||
Standard_Integer INext;
|
||||
INext = (IndexEdge == theCircuit->NumberOfItems()) ? 1 : (IndexEdge + 1);
|
||||
|
||||
Handle(Standard_Type) EdgeType = theCircuit->Value(IndexEdge)->DynamicType();
|
||||
@@ -535,7 +534,6 @@ Standard_Boolean MAT2d_Tool2d::Projection (const Standard_Integer IEdge ,
|
||||
Handle(Standard_Type) Type = Elt->DynamicType();
|
||||
Handle(Geom2d_TrimmedCurve) Curve;
|
||||
Standard_Integer INext;
|
||||
Standard_Real ParameterOnC;
|
||||
Standard_Real Eps = MAT2d_TOLCONF;//*10.;
|
||||
|
||||
if (Type == STANDARD_TYPE(Geom2d_CartesianPoint)) {
|
||||
@@ -586,7 +584,6 @@ Standard_Boolean MAT2d_Tool2d::Projection (const Standard_Integer IEdge ,
|
||||
if (Extremas.NbExt() == 0 ) return Standard_False; // Pas de solution!
|
||||
for (Standard_Integer i = 1; i <= Extremas.NbExt(); i++) {
|
||||
if (Extremas.SquareDistance(i) < Distance * Distance) {
|
||||
ParameterOnC = Extremas.Point(i).Parameter();
|
||||
Distance = sqrt (Extremas.SquareDistance(i));
|
||||
}
|
||||
}
|
||||
|
Reference in New Issue
Block a user