解決“std::Copy_impl”報錯問題

        在VS2013+Boost編程時常出現"std::Copy_impl"報錯問題,出現該問題的原因是VS2013把Copy裏參數轉化警告warning 4996提升爲error了,只需要*.cpp裏屏蔽掉這個warnning,如下:
//conHello2.cpp

#if defined(_MSC_VER) && _MSC_VER >= 1400 
#pragma warning(push) 
#pragma warning(disable:4996) 
#endif 


#include <iostream>
#include <vector>
#include <algorithm>

#include <boost/bind.hpp>
#include <boost/algorithm/string.hpp>
#include <boost/algorithm/string/regex.hpp>
#include <clocale>
發佈了524 篇原創文章 · 獲贊 798 · 訪問量 208萬+
發表評論
所有評論
還沒有人評論,想成為第一個評論的人麼? 請在上方評論欄輸入並且點擊發布.
相關文章