mirror of
https://git.dev.opencascade.org/repos/occt.git
synced 2025-08-14 13:30:48 +03:00
0024023: Revamp the OCCT Handle -- downcast (automatic)
Automatic update by command "occt_upgrade . -downcast" C-style cast of Handle to that of derived type (now illegal) is replaced by call to DownCast() Const reference local variables of Handle type initialized by result of DownCast are replaced by normal variables.
This commit is contained in:
@@ -1621,7 +1621,7 @@ void IntPatch_PrmPrmIntersection::Perform (const Handle(Adaptor3d_HSurface)&
|
||||
IntPatch_IType aType = aSLine->ArcType();
|
||||
if( aType != IntPatch_Walking)
|
||||
continue;
|
||||
const Handle(IntPatch_WLine)& aWLine = (*((Handle(IntPatch_WLine)*)&aSLine));
|
||||
Handle(IntPatch_WLine) aWLine (Handle(IntPatch_WLine)::DownCast (aSLine));
|
||||
Standard_Integer tnbV = aWLine->NbVertex();
|
||||
Standard_Integer tiV;
|
||||
for( tiV = 1; tiV <= tnbV; tiV++ ) {
|
||||
@@ -1645,7 +1645,7 @@ void IntPatch_PrmPrmIntersection::Perform (const Handle(Adaptor3d_HSurface)&
|
||||
|
||||
if( VDMin != 0 ) {
|
||||
const Handle(IntPatch_Line)& aSLine = SLin.Value(WLDMin);
|
||||
const Handle(IntPatch_WLine)& aWLine = (*((Handle(IntPatch_WLine)*)&aSLine));
|
||||
Handle(IntPatch_WLine) aWLine (Handle(IntPatch_WLine)::DownCast (aSLine));
|
||||
Standard_Integer tiVpar = (Standard_Integer)aWLine->Vertex(VDMin).ParameterOnLine();
|
||||
Standard_Integer ciVpar = (Standard_Integer)wline->Vertex(ciV).ParameterOnLine();
|
||||
Standard_Real u11 = 0., u12 = 0., v11 = 0., v12 = 0.;
|
||||
@@ -2441,7 +2441,7 @@ void IntPatch_PrmPrmIntersection::Perform (const Handle(Adaptor3d_HSurface)& Sur
|
||||
IntPatch_IType aType = aSLine->ArcType();
|
||||
if( aType != IntPatch_Walking)
|
||||
continue;
|
||||
const Handle(IntPatch_WLine)& aWLine = (*((Handle(IntPatch_WLine)*)&aSLine));
|
||||
Handle(IntPatch_WLine) aWLine (Handle(IntPatch_WLine)::DownCast (aSLine));
|
||||
Standard_Integer tnbV = aWLine->NbVertex();
|
||||
Standard_Integer tiV;
|
||||
for( tiV = 1; tiV <= tnbV; tiV++ )
|
||||
@@ -2469,7 +2469,7 @@ void IntPatch_PrmPrmIntersection::Perform (const Handle(Adaptor3d_HSurface)& Sur
|
||||
if( VDMin != 0 )
|
||||
{
|
||||
const Handle(IntPatch_Line)& aSLine = SLin.Value(WLDMin);
|
||||
const Handle(IntPatch_WLine)& aWLine = (*((Handle(IntPatch_WLine)*)&aSLine));
|
||||
Handle(IntPatch_WLine) aWLine (Handle(IntPatch_WLine)::DownCast (aSLine));
|
||||
Standard_Integer tiVpar = (Standard_Integer)aWLine->Vertex(VDMin).ParameterOnLine();
|
||||
Standard_Integer ciVpar = (Standard_Integer)wline->Vertex(ciV).ParameterOnLine();
|
||||
Standard_Real u11 = 0., u12 = 0., v11 = 0., v12 = 0.;
|
||||
|
Reference in New Issue
Block a user