問題タブ [pvs-studio]

For questions regarding programming in ECMAScript (JavaScript/JS) and its various dialects/implementations (excluding ActionScript). Note JavaScript is NOT the same as Java! Please include all relevant tags on your question; e.g., [node.js], [jquery], [json], [reactjs], [angular], [ember.js], [vue.js], [typescript], [svelte], etc.

0 投票する
1 に答える
145 参照

c++ - PVS-Studio が float 比較について不平を言う

PVS Studio アナライザーでコードをスキャンしましたが、このエラーの理由と修正方法について混乱しています。

V550 奇妙な正確な比較: * dest == value. fabs(A - B) < Epsilon.

私は次のようにコードを変更すると推測しています: