mirror of
https://github.com/Open-Cascade-SAS/OCCT.git
synced 2026-07-10 12:28:17 +08:00
0025622: CAST analysis: Avoid invocation of virtual Methods of the declared Class in a Constructor or Destructor
The Delete() methods have been deleted from the following classes: - Adaptor2d_Curve2d - Adaptor3d_Curve - Adaptor3d_Surface - AppBlend_Approx - AppCont_Function - AppParCurves_MultiCurve - AppParCurves_MultiPoint - ApproxInt_SvSurfaces - BRepPrim_OneAxis - BRepSweep_NumLinearRegularSweep - BRepSweep_Translation - BRepSweep_Trsf - DBC_BaseArray - GeomFill_Profiler - HatchGen_PointOnHatching - math_BFGS - math_FunctionSet - math_FunctionSetRoot - math_FunctionWithDerivative - math_MultipleVarFunction - math_MultipleVarFunctionWithHessian - math_MultipleVarFunctionWithGradient - math_Powell - math_NewtonMinimum - math_NewtonFunctionSetRoot - math_BissecNewton (just add virtual destructor) - math_FRPR - math_BrentMinimum (just add virtual destructor) - OSD_Chronometer - ProjLib_Projector Virtual methods Delete() or Destroy() of the transient inheritors is not changed (-> separate issue). Classes Graphic3d_DataStructureManager and PrsMgr_Presentation without changes.
This commit is contained in:
@@ -23,17 +23,12 @@ deferred class FunctionWithDerivative from math
|
||||
inherits Function
|
||||
|
||||
is
|
||||
|
||||
Delete(me:out) is virtual;
|
||||
---C++: alias "Standard_EXPORT virtual ~math_FunctionWithDerivative(){Delete();}"
|
||||
|
||||
Value(me: in out; X: Real; F: out Real)
|
||||
---Purpose: Computes the value <F>of the function for the variable <X>.
|
||||
-- Returns True if the calculation were successfully done,
|
||||
-- False otherwise.
|
||||
|
||||
returns Boolean
|
||||
is deferred;
|
||||
returns Boolean is deferred;
|
||||
|
||||
Derivative(me: in out; X: Real; D: out Real)
|
||||
---Purpose: Computes the derivative <D> of the function
|
||||
@@ -41,8 +36,7 @@ is
|
||||
-- Returns True if the calculation were successfully done,
|
||||
-- False otherwise.
|
||||
|
||||
returns Boolean
|
||||
is deferred;
|
||||
returns Boolean is deferred;
|
||||
|
||||
Values(me: in out; X: Real; F, D: out Real)
|
||||
---Purpose: Computes the value <F> and the derivative <D> of the
|
||||
@@ -50,7 +44,8 @@ is
|
||||
-- Returns True if the calculation were successfully done,
|
||||
-- False otherwise.
|
||||
|
||||
returns Boolean
|
||||
is deferred;
|
||||
returns Boolean is deferred;
|
||||
|
||||
---C++: alias " Standard_EXPORT virtual ~math_FunctionWithDerivative();"
|
||||
|
||||
end FunctionWithDerivative;
|
||||
|
||||
Reference in New Issue
Block a user