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

0026937: Eliminate NO_CXX_EXCEPTION macro support

Macro NO_CXX_EXCEPTION was removed from code.
Method Raise() was replaced by explicit throw statement.
Method Standard_Failure::Caught() was replaced by normal C++mechanism of exception transfer.
Method Standard_Failure::Caught() is deprecated now.
Eliminated empty constructors.
Updated samples.
Eliminate empty method ChangeValue from NCollection_Map class.
Removed not operable methods from NCollection classes.
This commit is contained in:
ski
2017-02-02 16:35:21 +03:00
committed by apn
parent 0c63f2f8b9
commit 9775fa6110
1146 changed files with 4860 additions and 6183 deletions

View File

@@ -34,7 +34,7 @@ math_EigenValuesSearcher::math_EigenValuesSearcher(const TColStd_Array1OfReal& D
Standard_Integer n = Diagonal.Length();
if (Subdiagonal.Length() != n)
Standard_Failure::Raise("math_EigenValuesSearcher : dimension mismatch");
throw Standard_Failure("math_EigenValuesSearcher : dimension mismatch");
myDiagonal = new TColStd_HArray1OfReal(1, n);
myDiagonal->ChangeArray1() = Diagonal;

View File

@@ -708,7 +708,7 @@ void math_FunctionSetRoot::Perform(math_FunctionSetWithDerivatives& F,
if ((Neq <= 0) ||
(StartingPoint.Length()!= Ninc) ||
(theInfBound.Length() != Ninc) ||
(theSupBound.Length() != Ninc)) { Standard_DimensionError:: Raise(); }
(theSupBound.Length() != Ninc)) { throw Standard_DimensionError(); }
Standard_Integer i;
Standard_Boolean ChangeDirection = Standard_False, Sort = Standard_False, isNewSol = Standard_False;

View File

@@ -61,7 +61,7 @@ math_Gauss::math_Gauss(const math_Matrix& A,
StdFail_NotDone_Raise_if(!Done, " ");
if(X.Length() != LU.RowNumber()) {
Standard_DimensionError::Raise();
throw Standard_DimensionError();
}
LU_Solve(LU,
Index,

View File

@@ -169,7 +169,7 @@ void math_Matrix::Invert()
Sol.Invert(*this);
}
else {
math_SingularMatrix::Raise(); // SingularMatrix Exception;
throw math_SingularMatrix(); // SingularMatrix Exception;
}
}

View File

@@ -27,7 +27,7 @@ DEFINE_STANDARD_HANDLE(math_NotSquare, Standard_DimensionError)
#if !defined No_Exception && !defined No_math_NotSquare
#define math_NotSquare_Raise_if(CONDITION, MESSAGE) \
if (CONDITION) math_NotSquare::Raise(MESSAGE);
if (CONDITION) throw math_NotSquare(MESSAGE);
#else
#define math_NotSquare_Raise_if(CONDITION, MESSAGE)
#endif

View File

@@ -27,7 +27,7 @@ DEFINE_STANDARD_HANDLE(math_SingularMatrix, Standard_Failure)
#if !defined No_Exception && !defined No_math_SingularMatrix
#define math_SingularMatrix_Raise_if(CONDITION, MESSAGE) \
if (CONDITION) math_SingularMatrix::Raise(MESSAGE);
if (CONDITION) throw math_SingularMatrix(MESSAGE);
#else
#define math_SingularMatrix_Raise_if(CONDITION, MESSAGE)
#endif