私は最近追加しました:
#define NOMINMAX
#include <Windows.h>
#include <algorithm>
使用するために私のmain.cppに
std::max( x , x ); // x is just a placeholder and not actual anything
std::min( x , x );
std::max()/std::min()
しかし、他のファイルでは使用できません。
error C2589: '(' : illegal token on right side of '::'
error C2059: syntax error : '::'
他のファイルを追加しようとしまし#define NOMINMAX
たが、失敗します。手がかりは何ですか?
質問する前に周りを見回しましたが、答えがわかりませんVisual C++ での NOMINMAX に関する問題の可能性