A typo in the condition
V501 There are identical sub-expressions to the left and to the right of the ‘-‘ operator: iA->getPoint2D() – iA->getPoint2D() curve.cpp 136
CurvePoint::CurvePoint(CurvePoint *iA, CurvePoint *iB, float t3) { .... if ((iA->getPoint2D() - iA->getPoint2D()).norm() < 1.0e-6) { .... } .... }
Inside the CurvePoint function the program handles two objects with similar names – iA and iB. Different methods of these objects get intersected all the time in various operations in quite a long tree of conditions. There is a typo in one of these conditional blocks. As a result we have a subtraction operation between the properties of one and the same object. Without knowing the peculiarities of the code, it’s quite hard to say, in which operand we have an error.
Please click here to see more bugs from this project.