Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- Vector3dF
- Matrix3F::SolveEigenproblem(Matrix3F* eigenvectors) const
- {
- // The matrix must be symmetric.
- const float epsilon = std::numeric_limits<float>::epsilon();
- if (std::abs(data_[M01] - data_[M10]) > epsilon ||
- std::abs(data_[M02] - data_[M02]) > epsilon ||
- std::abs(data_[M12] - data_[M21]) > epsilon) {
- NOTREACHED();
- return Vector3dF();
- }
- ....
- }
- This suspicious code was found in Chromium project by PVS-Studio static code analyzer.
- Warning message is:
- V501 There are identical sub-expressions to the left and to the right of the '-' operator: data_[M02] - data_[M02] matrix3_f.cc 128
- PVS-Studio is a static analyzer for detecting bugs in the source code of applications written in C, C++, C++11, C++/CX. Site: http://www.viva64.com/en/pvs-studio/
Advertisement
Add Comment
Please, Sign In to add comment