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

0022922: Clean up warnings on uninitialized / unused variables

This commit is contained in:
dbv@opencascade.com
2012-03-07 17:00:48 +04:00
committed by bugmaster
parent 25289ec1e1
commit 6e6cd5d949
226 changed files with 151 additions and 1471 deletions

View File

@@ -121,10 +121,6 @@ static Standard_Boolean MinimizeDirection(math_Vector& P,
F.Initialize(P, Dir);
Standard_Real dy1, Hnr1, lambda, alfa=0;
#ifdef DEB
Standard_Integer n =
#endif
Dir.Length();
dy1 = Gr*Dir;
if (dy1 != 0) {
Hnr1 = Dir.Norm2();

View File

@@ -130,7 +130,7 @@ math_BrentMinimum::math_BrentMinimum(const Standard_Real TolX,
// Standard_Boolean math_BrentMinimum::IsSolutionReached(math_Function& F) {
Standard_Boolean math_BrentMinimum::IsSolutionReached(math_Function& ) {
Standard_Real xm = 0.5 * (a + b);
// Standard_Real xm = 0.5 * (a + b);
// modified by NIZHNY-MKK Mon Oct 3 17:45:57 2005.BEGIN
// Standard_Real tol = XTol * fabs(x) + EPSZ;
// return fabs(x - xm) <= 2.0 * tol - 0.5 * (b - a);

View File

@@ -89,9 +89,6 @@ math_DoubleTab::math_DoubleTab(const math_DoubleTab& Other) :
void math_DoubleTab::Free()
{
Standard_Integer RowNumber = UppR - LowR + 1;
Standard_Integer ColNumber = UppC - LowC + 1;
// free the data
if(isAllocated) {
Standard_Address it = (Standard_Address)&Value(LowR,LowC);

View File

@@ -66,11 +66,7 @@ class math_MyFunctionSetWithDerivatives : public math_FunctionSetWithDerivatives
math_FunctionSetRoot Sol(Ff,V,Tol,NbIterations);
Done = Sol.IsDone();
if (Done) {
#ifdef DEB
Standard_Integer Ier=F.GetStateNumber();
#else
F.GetStateNumber();
#endif
TheRoot = Sol.Root()(1);
TheDerivative = Sol.Derivative()(1,1);
Ok = F.Value(TheRoot,TheError);
@@ -93,11 +89,7 @@ class math_MyFunctionSetWithDerivatives : public math_FunctionSetWithDerivatives
math_FunctionSetRoot Sol(Ff,V,Tol,Aa,Bb,NbIterations);
Done = Sol.IsDone();
if (Done) {
#ifdef DEB
Standard_Integer Ier =F.GetStateNumber();
#else
F.GetStateNumber();
#endif
TheRoot = Sol.Root()(1);
TheDerivative = Sol.Derivative()(1,1);
Ok = F.Value(TheRoot,TheError);

View File

@@ -980,16 +980,6 @@ math_FunctionRoots::math_FunctionRoots(math_FunctionWithDerivative& F,
if(n1>n2) n=n2;
for(Standard_Integer i=1;i<=n;i++) {
Standard_Real t = Sol(i)-StaticSol(i);
#ifdef NEWSEQ
# ifdef DEB
Standard_Real t1=
# endif
Sol(i);
# ifdef DEB
Standard_Real t2=
# endif
StaticSol(i);
#endif
if(Abs(t)>NEpsX) {
printf("\n mathFunctionRoots : i:%d/%d delta: %g",i,n,t);
}

View File

@@ -328,9 +328,6 @@ math_IntegerVector& math_IntegerVector::Initialized (const math_IntegerVector& O
Standard_DimensionError_Raise_if(Length() != Other.Length(), " ");
#ifdef DEB
Standard_Integer I = Other.FirstIndex;
#endif
(Other.Array).Copy(Array);
return *this;
}

View File

@@ -74,7 +74,7 @@ void math_KronrodSingleIntegration::Perform
const Standard_Real theUpper,
const Standard_Integer theNbPnts)
{
const Standard_Real aMinVol = Epsilon(1.);
//const Standard_Real aMinVol = Epsilon(1.);
const Standard_Real aPtol = 1.e-9;
myNbIterReached = 0;
@@ -110,7 +110,7 @@ void math_KronrodSingleIntegration::Perform
if(!myIsDone) return;
Standard_Real anAbsVal = Abs(myValue);
//Standard_Real anAbsVal = Abs(myValue);
myAbsolutError = myErrorReached;
@@ -267,7 +267,6 @@ Standard_Boolean math_KronrodSingleIntegration::GKRule(
Standard_Boolean IsDone;
Standard_Integer aNGauss = theGaussP.Length();
Standard_Integer aNKronrod = theKronrodP.Length();
Standard_Real aGaussVal;

View File

@@ -63,9 +63,6 @@ class MyTrigoFunction: public math_FunctionWithDerivative {
//-- F= AA*CN*CN+2*BB*CN*SN+CC*CN+DD*SN+EE;
//-- D = -2*AA*CN*SN+2*BB*(CN*CN-SN*SN)-CC*SN+DD*CN;
Standard_Real AACN = AA*CN;
#ifdef DEB
Standard_Real BBCN = BB*CN;
#endif
Standard_Real BBSN = BB*SN;
F = AACN*CN + BBSN*(CN+CN) + CC*CN + DD*SN + EE;

View File

@@ -429,9 +429,6 @@ math_Vector math_Vector::Multiplied(const math_Matrix& Right)const {
Standard_DimensionError_Raise_if(Length() != Right.RowNumber(), "");
math_Vector Result(Right.LowerColIndex, Right.UpperColIndex);
#ifdef DEB
Standard_Integer Index = LowerIndex;
#endif
for(Standard_Integer J2 = Right.LowerColIndex;
J2 <= Right.UpperColIndex; J2++) {
Array(J2) = 0.0;