mirror of
https://git.dev.opencascade.org/repos/occt.git
synced 2025-08-09 13:22:24 +03:00
0024955: Misuse of DownCast
Code where DownCast was applied to Handle of the type being not a base class of the target one is revised and (hopefully) corrected. Code corrected following review remarks GeomConvert::CurveToBSplineCurve() is called even for b-spline curves to ensure that result is non-periodic Check for conic is corrected
This commit is contained in:
@@ -93,7 +93,7 @@ is
|
||||
---Purpose: Sets the tool for dividing edges on Face.
|
||||
|
||||
GetSplitSurfaceTool (me) returns SplitSurface from ShapeUpgrade
|
||||
is virtual protected;
|
||||
is virtual;
|
||||
---Purpose: Returns the tool for splitting surfaces.
|
||||
-- This tool must be already initialized.
|
||||
|
||||
|
@@ -73,7 +73,7 @@ double ShapeUpgrade_ShapeDivideAngle::MaxAngle () const
|
||||
Handle(ShapeUpgrade_FaceDivide) faceTool = GetSplitFaceTool();
|
||||
if ( faceTool.IsNull() ) return 0.;
|
||||
Handle(ShapeUpgrade_SplitSurfaceAngle) tool =
|
||||
Handle(ShapeUpgrade_SplitSurfaceAngle)::DownCast ( faceTool );
|
||||
Handle(ShapeUpgrade_SplitSurfaceAngle)::DownCast (faceTool->GetSplitSurfaceTool());
|
||||
return ( tool.IsNull() ? 0. : tool->MaxAngle() );
|
||||
}
|
||||
|
||||
|
Reference in New Issue
Block a user