1

このような警告が表示されたときに、コード内の関連する場所を見つけるスマートな方法はありますか? 表示されている唯一の行番号は標準ヘッダーを参照しているようですが、実際のコードではありません。プロジェクトは数百のモジュールと 1MLOC+ を含む非常に大規模なものであることを付け加えておきます。

C:\Program Files (x86)\Microsoft Visual Studio 11.0\VC\include\utility(138): warning C4800: 'int' : forcing value to bool 'true' or 'false' (performance warning)
          C:\Program Files (x86)\Microsoft Visual Studio 11.0\VC\include\xtree(1804) : see reference to function template instantiation 'std::pair<_Ty1,_Ty2>::pair<std::_Tree_iterator<_Mytree>,int>(_Other1 &&,_Other2 &&,void **)' being compiled
          with
          [
              _Ty1=std::_Tree_iterator<std::_Tree_val<std::_Tree_simple_types<std::pair<const std::string,tpuTask >>>>,
              _Ty2=bool,
              _Mytree=std::_Tree_val<std::_Tree_simple_types<std::pair<const std::string,tpuTask >>>,
              _Other1=std::_Tree_iterator<std::_Tree_val<std::_Tree_simple_types<std::pair<const std::string,tpuTask >>>>,
              _Other2=int
          ]
          C:\Program Files (x86)\Microsoft Visual Studio 11.0\VC\include\xtree(1804) : see reference to function template instantiation 'std::pair<_Ty1,_Ty2>::pair<std::_Tree_iterator<_Mytree>,int>(_Other1 &&,_Other2 &&,void **)' being compiled
          with
          [
              _Ty1=std::_Tree_iterator<std::_Tree_val<std::_Tree_simple_types<std::pair<const std::string,tpuTask >>>>,
              _Ty2=bool,
              _Mytree=std::_Tree_val<std::_Tree_simple_types<std::pair<const std::string,tpuTask >>>,
              _Other1=std::_Tree_iterator<std::_Tree_val<std::_Tree_simple_types<std::pair<const std::string,tpuTask >>>>,
              _Other2=int
          ]
...
4

1 に答える 1