0029712: Extrema algorithm raises exception
[occt.git] / src / Extrema / Extrema_GenLocateExtPC.gxx
index 7908247..dfc62eb 100644 (file)
@@ -139,7 +139,10 @@ Standard_Boolean Extrema_GenLocateExtPC::IsDone () const
 
 Standard_Real Extrema_GenLocateExtPC::SquareDistance() const 
 {
-  if (!myDone) { throw StdFail_NotDone(); }
+  if (!IsDone())
+  {
+    throw StdFail_NotDone();
+  }
   return myF.SquareDistance(1);
 }
 
@@ -151,7 +154,10 @@ Standard_Real Extrema_GenLocateExtPC::SquareDistance() const
 
 Standard_Boolean Extrema_GenLocateExtPC::IsMin () const 
 {
-  if (!myDone) { throw StdFail_NotDone(); }
+  if (!IsDone())
+  {
+    throw StdFail_NotDone();
+  }
   return myF.IsMin(1);
 }
 
@@ -163,7 +169,10 @@ Standard_Boolean Extrema_GenLocateExtPC::IsMin () const
 
 const POnC & Extrema_GenLocateExtPC::Point () const 
 {
-  if (!myDone) { throw StdFail_NotDone(); }
+  if (!IsDone())
+  {
+    throw StdFail_NotDone();
+  }
   return myF.Point(1);
 }