diff --git a/src/BRepClass3d/BRepClass3d_SClassifier.cxx b/src/BRepClass3d/BRepClass3d_SClassifier.cxx index 16e0bf8495..edc87e24d4 100644 --- a/src/BRepClass3d/BRepClass3d_SClassifier.cxx +++ b/src/BRepClass3d/BRepClass3d_SClassifier.cxx @@ -313,11 +313,14 @@ void BRepClass3d_SClassifier::Perform(BRepClass3d_SolidExplorer& SolidExplorer, continue; TopoDS_Face f1 = TopoDS::Face(ffs.First()); TopoDS_Face f2 = TopoDS::Face(ffs.Last()); - IntCurveSurface_TransitionOnCurve tran; TopoDS_Vertex V1, V2; TopExp::Vertices(EE, V1, V2); if (LVInts.Contains(V1) || LVInts.Contains(V2)) + { continue; + } + + IntCurveSurface_TransitionOnCurve tran = IntCurveSurface_Tangent; Standard_Integer Tst = GetTransi(f1, f2, EE, param, L, tran); if (Tst == 1 && Abs(Lpar) < Abs(parmin)) { diff --git a/src/Bisector/Bisector_BisecAna.cxx b/src/Bisector/Bisector_BisecAna.cxx index baeda5fe5b..6e5330d7ec 100644 --- a/src/Bisector/Bisector_BisecAna.cxx +++ b/src/Bisector/Bisector_BisecAna.cxx @@ -839,11 +839,8 @@ void Bisector_BisecAna::Perform(const Handle(Geom2d_Curve)& afirstcurve , } aFirstCurveType = curve->DynamicType(); -#ifdef OCCT_DEBUG - gp_Pnt2d Point(asecondpoint->Pnt2d()); -#else - asecondpoint->Pnt2d(); -#endif + const gp_Pnt2d aPoint(asecondpoint->Pnt2d()); + (void )aPoint; if (aFirstCurveType == STANDARD_TYPE(Geom2d_Circle)) { cas = 1; Handle(Geom2d_Circle) C1 = Handle(Geom2d_Circle)::DownCast(curve); diff --git a/src/DNaming/DNaming_Line3DDriver.cxx b/src/DNaming/DNaming_Line3DDriver.cxx index 438ab05d96..1cc2c616a2 100644 --- a/src/DNaming/DNaming_Line3DDriver.cxx +++ b/src/DNaming/DNaming_Line3DDriver.cxx @@ -118,13 +118,15 @@ Standard_Integer DNaming_Line3DDriver::Execute(Handle(TFunction_Logbook)& theLog #ifdef OCCT_DEBUG if(!aNS1->IsEmpty()) { aShape1 = aNS1->Get(); - gp_Pnt aDebPoint = BRep_Tool::Pnt(TopoDS::Vertex(aShape1)); + const gp_Pnt aDebPoint = BRep_Tool::Pnt(TopoDS::Vertex(aShape1)); + (void )aDebPoint; // cout << aCounter << " X = " << aDebPoint.X() << " Y = " << aDebPoint.Y() << " Z = " << aDebPoint.Z() << endl; } else cout << " Line3DDriver:: NS1 is empty" << endl; if(!aNS2->IsEmpty()) { aShape2 = aNS2->Get(); - gp_Pnt aDebPoint = BRep_Tool::Pnt(TopoDS::Vertex(aShape2)); + const gp_Pnt aDebPoint = BRep_Tool::Pnt(TopoDS::Vertex(aShape2)); + (void )aDebPoint; // cout << aCounter+1 << " X = " << aDebPoint.X() << " Y = " << aDebPoint.Y() << " Z = " << aDebPoint.Z() << endl; } else cout << " Line3DDriver:: NS2 is empty" << endl; @@ -137,10 +139,12 @@ Standard_Integer DNaming_Line3DDriver::Execute(Handle(TFunction_Logbook)& theLog aShape1 = aNS1->Get(); aShape2 = aNS2->Get(); #ifdef OCCT_DEBUG - gp_Pnt aDebPoint = BRep_Tool::Pnt(TopoDS::Vertex(aShape1)); - // cout << aCounter << " X = " << aDebPoint.X() << " Y = " << aDebPoint.Y() << " Z = " << aDebPoint.Z() << endl; - aDebPoint = BRep_Tool::Pnt(TopoDS::Vertex(aShape2)); - // cout << aCounter+1 << " X = " << aDebPoint.X() << " Y = " << aDebPoint.Y() << " Z = " << aDebPoint.Z() << endl; + const gp_Pnt aDebPoint1 = BRep_Tool::Pnt(TopoDS::Vertex(aShape1)); + const gp_Pnt aDebPoint2 = BRep_Tool::Pnt(TopoDS::Vertex(aShape2)); + // cout << aCounter << " X = " << aDebPoint1.X() << " Y = " << aDebPoint1.Y() << " Z = " << aDebPoint1.Z() << endl; + // cout << aCounter+1 << " X = " << aDebPoint2.X() << " Y = " << aDebPoint2.Y() << " Z = " << aDebPoint2.Z() << endl; + (void )aDebPoint1; + (void )aDebPoint2; #endif if(aShape1.ShapeType() != TopAbs_VERTEX || aShape2.ShapeType() != TopAbs_VERTEX) { aFunction->SetFailure(WRONG_ARGUMENT); diff --git a/src/GccAna/GccAna_Circ2d3Tan_1.cxx b/src/GccAna/GccAna_Circ2d3Tan_1.cxx index 21b29bbf20..4550d81446 100644 --- a/src/GccAna/GccAna_Circ2d3Tan_1.cxx +++ b/src/GccAna/GccAna_Circ2d3Tan_1.cxx @@ -89,11 +89,9 @@ GccAna_Circ2d3Tan:: Standard_Real R1 = C1.Radius(); Standard_Real R2 = C2.Radius(); gp_Pnt2d center1(C1.Location()); -#ifdef OCCT_DEBUG gp_Pnt2d center2(C2.Location()); -#else - C2.Location() ; -#endif + (void )center2; + gp_Pnt2d origin3(L3.Location()); gp_Dir2d dir3(L3.Direction()); gp_Dir2d normL3(-dir3.Y(),dir3.X()); diff --git a/src/GccAna/GccAna_Circ2d3Tan_6.cxx b/src/GccAna/GccAna_Circ2d3Tan_6.cxx index 005760b276..4e795a9025 100644 --- a/src/GccAna/GccAna_Circ2d3Tan_6.cxx +++ b/src/GccAna/GccAna_Circ2d3Tan_6.cxx @@ -93,18 +93,14 @@ GccAna_Circ2d3Tan:: Standard_Integer nbsolution1 = Bis1.NbSolutions(); Handle(GccInt_Bisec) Sol2 = Bis2.ThisSolution(); for (Standard_Integer i = 1 ; i <= nbsolution1; i++) { -#ifdef OCCT_DEBUG - gp_Lin2d Sol1(Bis1.ThisSolution(i)); -#else - Bis1.ThisSolution(i) ; -#endif + const gp_Lin2d Sol1(Bis1.ThisSolution(i)); GccInt_IType typ2 = Sol2->ArcType(); IntAna2d_AnaIntersection Intp; if (typ2 == GccInt_Lin) { - Intp.Perform(Bis1.ThisSolution(i),Sol2->Line()); + Intp.Perform(Sol1,Sol2->Line()); } else if (typ2 == GccInt_Par) { - Intp.Perform(Bis1.ThisSolution(i),IntAna2d_Conic(Sol2->Parabola())); + Intp.Perform(Sol1,IntAna2d_Conic(Sol2->Parabola())); } if (Intp.IsDone()) { if (!Intp.IsEmpty()) { diff --git a/src/GccAna/GccAna_Circ2d3Tan_8.cxx b/src/GccAna/GccAna_Circ2d3Tan_8.cxx index 33a0c0b52c..6c23405567 100644 --- a/src/GccAna/GccAna_Circ2d3Tan_8.cxx +++ b/src/GccAna/GccAna_Circ2d3Tan_8.cxx @@ -88,14 +88,9 @@ GccAna_Circ2d3Tan:: GccAna_Pnt2dBisec Bis1(Point2,Point3); GccAna_LinPnt2dBisec Bis2(L1,Point2); if (Bis1.IsDone() && Bis2.IsDone()) { - gp_Lin2d linint1(Bis1.ThisSolution()); + const gp_Lin2d linint1(Bis1.ThisSolution()); Handle(GccInt_Bisec) Sol2 = Bis2.ThisSolution(); GccInt_IType typ2 = Sol2->ArcType(); -#ifdef OCCT_DEBUG - gp_Lin2d linintb(Bis1.ThisSolution()); -#else - Bis1.ThisSolution() ; -#endif IntAna2d_AnaIntersection Intp; if (typ2 == GccInt_Lin) { gp_Lin2d linint2(Sol2->Line()); diff --git a/src/IntCurveSurface/IntCurveSurface_Inter.gxx b/src/IntCurveSurface/IntCurveSurface_Inter.gxx index 3038684199..e0bad0682a 100644 --- a/src/IntCurveSurface/IntCurveSurface_Inter.gxx +++ b/src/IntCurveSurface/IntCurveSurface_Inter.gxx @@ -942,12 +942,8 @@ void IntCurveSurface_Inter::PerformConicSurf(const gp_Lin& Line, Standard_Integer nbp = intlintorus.NbPoints(); Standard_Real fi,theta,w; for(Standard_Integer i = 1; i<= nbp; i++) { -#ifndef OCCT_DEBUG - gp_Pnt P; - P = intlintorus.Value(i); -#else - gp_Pnt P(intlintorus.Value(i)); -#endif + const gp_Pnt aDebPnt(intlintorus.Value(i)); + (void )aDebPnt; w = intlintorus.ParamOnLine(i); intlintorus.ParamOnTorus(i,fi,theta); AppendPoint(curve,w,surface,fi,theta); diff --git a/src/Message/Message_Report.cxx b/src/Message/Message_Report.cxx index 012c644dd8..07324599d2 100644 --- a/src/Message/Message_Report.cxx +++ b/src/Message/Message_Report.cxx @@ -37,7 +37,7 @@ Message_Report::Message_Report () void Message_Report::AddAlert (Message_Gravity theGravity, const Handle(Message_Alert)& theAlert) { Standard_ASSERT_RETURN (! theAlert.IsNull(), "Attempt to add null alert",); - Standard_ASSERT_RETURN (theGravity >= 0 && theGravity < sizeof(myAlerts)/sizeof(myAlerts[0]), + Standard_ASSERT_RETURN (theGravity >= 0 && size_t(theGravity) < sizeof(myAlerts)/sizeof(myAlerts[0]), "Adding alert with gravity not in valid range",); Standard_Mutex::Sentry aSentry (myMutex); @@ -68,7 +68,7 @@ void Message_Report::AddAlert (Message_Gravity theGravity, const Handle(Message_ const Message_ListOfAlert& Message_Report::GetAlerts (Message_Gravity theGravity) const { static const Message_ListOfAlert anEmptyList; - Standard_ASSERT_RETURN (theGravity >= 0 && theGravity < sizeof(myAlerts)/sizeof(myAlerts[0]), + Standard_ASSERT_RETURN (theGravity >= 0 && size_t(theGravity) < sizeof(myAlerts)/sizeof(myAlerts[0]), "Requesting alerts for gravity not in valid range", anEmptyList); return myAlerts[theGravity]; } @@ -95,7 +95,7 @@ Standard_Boolean Message_Report::HasAlert (const Handle(Standard_Type)& theType) Standard_Boolean Message_Report::HasAlert (const Handle(Standard_Type)& theType, Message_Gravity theGravity) { - Standard_ASSERT_RETURN (theGravity >= 0 && theGravity < sizeof(myAlerts)/sizeof(myAlerts[0]), + Standard_ASSERT_RETURN (theGravity >= 0 && size_t(theGravity) < sizeof(myAlerts)/sizeof(myAlerts[0]), "Requesting alerts for gravity not in valid range", Standard_False); for (Message_ListOfAlert::Iterator anIt (myAlerts[theGravity]); anIt.More(); anIt.Next()) { @@ -125,7 +125,7 @@ void Message_Report::Clear () void Message_Report::Clear (Message_Gravity theGravity) { - Standard_ASSERT_RETURN (theGravity >= 0 && theGravity < sizeof(myAlerts)/sizeof(myAlerts[0]), + Standard_ASSERT_RETURN (theGravity >= 0 && size_t(theGravity) < sizeof(myAlerts)/sizeof(myAlerts[0]), "Requesting alerts for gravity not in valid range", ); myAlerts[theGravity].Clear(); } @@ -173,7 +173,7 @@ void Message_Report::Dump (Standard_OStream& theOS) void Message_Report::Dump (Standard_OStream& theOS, Message_Gravity theGravity) { - Standard_ASSERT_RETURN (theGravity >= 0 && theGravity < sizeof(myAlerts)/sizeof(myAlerts[0]), + Standard_ASSERT_RETURN (theGravity >= 0 && size_t(theGravity) < sizeof(myAlerts)/sizeof(myAlerts[0]), "Requesting alerts for gravity not in valid range", ); // report each type of warning only once @@ -208,7 +208,7 @@ void Message_Report::SendMessages (const Handle(Message_Messenger)& theMessenger void Message_Report::SendMessages (const Handle(Message_Messenger)& theMessenger, Message_Gravity theGravity) { - Standard_ASSERT_RETURN (theGravity >= 0 && theGravity < sizeof(myAlerts)/sizeof(myAlerts[0]), + Standard_ASSERT_RETURN (theGravity >= 0 && size_t(theGravity) < sizeof(myAlerts)/sizeof(myAlerts[0]), "Requesting alerts for gravity not in valid range", ); // report each type of warning only once