summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorFotios Sioutis <sfotis@gmail.com>2011-11-10 12:01:51 +0200
committerFotios Sioutis <sfotis@gmail.com>2011-11-11 23:16:11 +0200
commit05476b256be8aab0fec689c70ed83dd48dc3fdd6 (patch)
tree79f1f8a192cb9c0fd732e45d3bcc1d3a3b6dbf79
parent372ed506e93f7135afad6af75ab5e381cfae8c40 (diff)
downloadoce-05476b256be8aab0fec689c70ed83dd48dc3fdd6.tar.gz
oce-05476b256be8aab0fec689c70ed83dd48dc3fdd6.zip
Disambiguate using type casts under latest bcc32
Under the latest embarcadero compiler there exist some cases where the compiler cannot decide which operators to use.Using type casts we overcome this issue and the compilation proceeds without any further issues.
-rw-r--r--inc/Select3D_Pnt.hxx2
-rw-r--r--inc/Select3D_Pnt2d.hxx2
-rw-r--r--inc/Select3D_SensitiveSegment.lxx8
-rw-r--r--src/STEPConstruct/STEPConstruct_ValidationProps.cxx4
-rw-r--r--src/Select3D/Select3D_SensitiveCircle.cxx4
-rw-r--r--src/Select3D/Select3D_SensitivePoint.cxx2
-rw-r--r--src/TNaming/TNaming_UsedShapes.cxx4
-rw-r--r--src/UnitsAPI/UnitsAPI.cxx2
8 files changed, 14 insertions, 14 deletions
diff --git a/inc/Select3D_Pnt.hxx b/inc/Select3D_Pnt.hxx
index a1944cce..333710c5 100644
--- a/inc/Select3D_Pnt.hxx
+++ b/inc/Select3D_Pnt.hxx
@@ -24,7 +24,7 @@ struct Select3D_Pnt{
x = DToF(thePnt.X());
y = DToF(thePnt.Y());
z = DToF(thePnt.Z());
- return *this;
+ return (gp_Pnt)*this;
}
};
diff --git a/inc/Select3D_Pnt2d.hxx b/inc/Select3D_Pnt2d.hxx
index 042d9437..83eaaf43 100644
--- a/inc/Select3D_Pnt2d.hxx
+++ b/inc/Select3D_Pnt2d.hxx
@@ -23,7 +23,7 @@ struct Select3D_Pnt2d{
{
x = DToF(thePnt.X());
y = DToF(thePnt.Y());
- return *this;
+ return (gp_Pnt2d)*this;
}
diff --git a/inc/Select3D_SensitiveSegment.lxx b/inc/Select3D_SensitiveSegment.lxx
index ddf1f5b8..9c27d382 100644
--- a/inc/Select3D_SensitiveSegment.lxx
+++ b/inc/Select3D_SensitiveSegment.lxx
@@ -20,16 +20,16 @@ inline void Select3D_SensitiveSegment::EndPoint (const gp_Pnt& end)
}
inline gp_Pnt Select3D_SensitiveSegment::StartPoint () const
-{return mystart;}
+{return (gp_Pnt)mystart;}
inline gp_Pnt Select3D_SensitiveSegment::EndPoint () const
-{return myend;}
+{return (gp_Pnt)myend;}
inline gp_Pnt2d Select3D_SensitiveSegment::StartPoint2d () const
-{return myprojstart;}
+{return (gp_Pnt2d)myprojstart;}
inline gp_Pnt2d Select3D_SensitiveSegment::EndPoint2d () const
-{return myprojend;}
+{return (gp_Pnt2d)myprojend;}
inline Standard_Integer Select3D_SensitiveSegment::MaxBoxes()
const {return mymaxrect;}
diff --git a/src/STEPConstruct/STEPConstruct_ValidationProps.cxx b/src/STEPConstruct/STEPConstruct_ValidationProps.cxx
index 4b39b040..001ef6d7 100644
--- a/src/STEPConstruct/STEPConstruct_ValidationProps.cxx
+++ b/src/STEPConstruct/STEPConstruct_ValidationProps.cxx
@@ -663,7 +663,7 @@ Standard_Boolean STEPConstruct_ValidationProps::GetPropReal (const Handle(StepRe
else if ( Name == "VOLUME_MEASURE" ) isArea = Standard_False;
else {
#ifdef DEB
- cout << "Warning: Measure " << Model()->StringLabel ( M ) << " is neither area not volume" << endl;
+ cout << "Warning: Measure " << (const void*) Model()->StringLabel ( M ) << " is neither area not volume" << endl;
#endif
return Standard_False;
}
@@ -686,7 +686,7 @@ Standard_Boolean STEPConstruct_ValidationProps::GetPropPnt (const Handle(StepRep
Handle(StepGeom_CartesianPoint) P = Handle(StepGeom_CartesianPoint)::DownCast ( item );
if ( P.IsNull() || P->NbCoordinates() != 3 ) {
#ifdef DEB
- cout << "Warning: Point " << Model()->StringLabel ( P ) << " is not valid for centroid" << endl;
+ cout << "Warning: Point " << (const void*) Model()->StringLabel ( P ) << " is not valid for centroid" << endl;
#endif
return Standard_False;;
}
diff --git a/src/Select3D/Select3D_SensitiveCircle.cxx b/src/Select3D/Select3D_SensitiveCircle.cxx
index 21b1da02..d0680fea 100644
--- a/src/Select3D/Select3D_SensitiveCircle.cxx
+++ b/src/Select3D/Select3D_SensitiveCircle.cxx
@@ -277,8 +277,8 @@ gp_Pnt Select3D_SensitiveCircle::
GetPoint3d(const Standard_Integer Rank) const
{
if(Rank>=0&& Rank<mynbpoints)
- return ((Select3D_Pnt*)mypolyg3d)[Rank];
- return ((Select3D_Pnt*)mypolyg3d)[0];
+ return (gp_Pnt)((Select3D_Pnt*)mypolyg3d)[Rank];
+ return (gp_Pnt)((Select3D_Pnt*)mypolyg3d)[0];
}
diff --git a/src/Select3D/Select3D_SensitivePoint.cxx b/src/Select3D/Select3D_SensitivePoint.cxx
index 7c0115a0..a02bebe9 100644
--- a/src/Select3D/Select3D_SensitivePoint.cxx
+++ b/src/Select3D/Select3D_SensitivePoint.cxx
@@ -121,7 +121,7 @@ Matches (const TColgp_Array1OfPnt2d& aPoly,
//purpose :
//=======================================================================
gp_Pnt Select3D_SensitivePoint::Point() const
-{return mypoint;}
+{return (gp_Pnt)mypoint;}
//=======================================================================
//function : GetConnected
diff --git a/src/TNaming/TNaming_UsedShapes.cxx b/src/TNaming/TNaming_UsedShapes.cxx
index 313d8b7a..ede64598 100644
--- a/src/TNaming/TNaming_UsedShapes.cxx
+++ b/src/TNaming/TNaming_UsedShapes.cxx
@@ -159,8 +159,8 @@ Standard_OStream& TNaming_UsedShapes::Dump(Standard_OStream& anOS) const
TopAbs::Print(itr.Key().ShapeType(),anOS);
anOS<<" ";
itr.Value()->Label().EntryDump(anOS);
- anOS << " Key_TShape = " <<itr.Key().TShape()->This();
- anOS << " Value_TShape = " <<itr.Value()->Shape().TShape()->This();
+ anOS << " Key_TShape = " <<(const void*)itr.Key().TShape()->This();
+ anOS << " Value_TShape = " <<(const void*)itr.Value()->Shape().TShape()->This();
anOS<<endl;
}
#endif
diff --git a/src/UnitsAPI/UnitsAPI.cxx b/src/UnitsAPI/UnitsAPI.cxx
index 0dc383c4..7b0d104c 100644
--- a/src/UnitsAPI/UnitsAPI.cxx
+++ b/src/UnitsAPI/UnitsAPI.cxx
@@ -338,7 +338,7 @@ Standard_Real UnitsAPI::AnyToLS(const Standard_Real aData,
aValue = LocalSystemUnits.ConvertSIValueToUserSystem(quantity,aValue);
}
else
- cout<<"Warning: BAD Quantity returns in UnitsAPI::AnyToLS(" << aData << "," << aUnit << "," << aDim << ")" << endl;
+ cout<<"Warning: BAD Quantity returns in UnitsAPI::AnyToLS(" << aData << "," << aUnit << "," << (const void*)aDim << ")" << endl;
return aValue;
}