• <ins id="pjuwb"></ins>
    <blockquote id="pjuwb"><pre id="pjuwb"></pre></blockquote>
    <noscript id="pjuwb"></noscript>
          <sup id="pjuwb"><pre id="pjuwb"></pre></sup>
            <dd id="pjuwb"></dd>
            <abbr id="pjuwb"></abbr>

            Error

            C++博客 首頁 新隨筆 聯系 聚合 管理
              217 Posts :: 61 Stories :: 32 Comments :: 0 Trackbacks
            搞了搞split,發現boost里邊已經有了,就拿過來直接用,之前翻了下facebook的,也沒見比boost更容易讀,還是boost算了。
            在vs2012上編譯了一下,發現有問題:error C4996: 'std::_Copy_impl': Function call with para

            找了下,老外是這么說的:http://stackoverflow.com/questions/14141476/warning-with-boostsplit-when-compiling

            You haven't done anything wrong. Visual Studio is being overly cautious. In debug mode, visual studio uses something called "Checked Iterators". Pointers are also iterators, but the checking mechanism doesn't work with them. So when a standard library algorithm is called with pointers, which is something that boost::split does, it issues this warning.

            You'll get the same warning with this obviously safe code:

            int main()
            {
                int x[10] = {};
                int y[10] = {};
                int *a = x, *b = y;
                std::copy(a, a+10, b);
            }

            Disable the warning. It's for beginners. It's on by default for the safety of beginners, because if it was off by default, they wouldn't know how to turn it on.





            #include <boost/algorithm/string/classification.hpp>
            #include <boost/algorithm/string.hpp>
            void LearnSplit()
            {
                std::string strTem("1,2,3,4");
                std::list<std::string> listStrTem;
                std::vector<std::string> vectorStrTem;
                boost::split(listStrTem, strTem, boost::is_any_of(","));
                boost::split(vectorStrTem, strTem, boost::is_any_of(","));
                for(auto item : listStrTem)
                {
                    std::cout << item.c_str() << std::endl;
                }
                std::string s = "Hello, the beautiful world!";
                std::vector<std::string> rs;
                boost::split( rs, s, boost::is_any_of( " ,!" ), boost::token_compress_on );
            }
            int _tmain(int argc, _TCHAR* argv[])
            {
                LearnSplit();
            return 0;
            }
            posted on 2013-04-11 00:29 Enic 閱讀(1058) 評論(0)  編輯 收藏 引用 所屬分類: boost
            2021国内精品久久久久久影院| 精品久久人人做人人爽综合 | 久久久久久一区国产精品| 99久久精品免费观看国产| 久久久久国产亚洲AV麻豆| 伊人久久大香线蕉综合影院首页| 欧美一区二区三区久久综| 精品无码人妻久久久久久| 久久无码中文字幕东京热| 伊人久久综合热线大杳蕉下载| 日日狠狠久久偷偷色综合免费 | 老色鬼久久亚洲AV综合| 久久精品国产一区二区三区| 中文字幕乱码人妻无码久久| 国产成人久久久精品二区三区| 伊人久久久AV老熟妇色| 国产精自产拍久久久久久蜜| 色综合久久久久无码专区| 久久伊人五月天论坛| 久久精品国产亚洲综合色| 亚洲欧洲日产国码无码久久99| 亚洲嫩草影院久久精品| 伊人久久综合成人网| 亚洲一区精品伊人久久伊人 | av色综合久久天堂av色综合在| 久久精品无码一区二区app| 精品国产福利久久久| 99久久国产宗和精品1上映| 亚洲欧洲精品成人久久曰影片| 91精品婷婷国产综合久久| 久久精品中文騷妇女内射| 一本久久a久久精品vr综合| 色综合久久夜色精品国产| 精品国产VA久久久久久久冰| 97视频久久久| 久久久久高潮综合影院| 亚洲日本久久久午夜精品| 欧美久久久久久| 久久亚洲AV无码精品色午夜麻豆| 精品久久久久成人码免费动漫| 亚洲精品tv久久久久久久久久|