[Orxonox-commit 6119] r10777 - in code/branches/cpp11_v2/src/libraries: core util

landauf at orxonox.net landauf at orxonox.net
Sun Nov 8 11:16:22 CET 2015


Author: landauf
Date: 2015-11-08 11:16:22 +0100 (Sun, 08 Nov 2015)
New Revision: 10777

Modified:
   code/branches/cpp11_v2/src/libraries/core/Loader.cc
   code/branches/cpp11_v2/src/libraries/util/StringUtils.cc
Log:
replacing boost::scoped_ptr/array with 'const std::unique_ptr'

Modified: code/branches/cpp11_v2/src/libraries/core/Loader.cc
===================================================================
--- code/branches/cpp11_v2/src/libraries/core/Loader.cc	2015-11-08 10:11:00 UTC (rev 10776)
+++ code/branches/cpp11_v2/src/libraries/core/Loader.cc	2015-11-08 10:16:22 UTC (rev 10777)
@@ -30,7 +30,6 @@
 
 #include <sstream>
 #include <tinyxml/ticpp.h>
-#include <boost/scoped_ptr.hpp>
 #include <boost/filesystem.hpp>
 #include <boost/filesystem/fstream.hpp>
 
@@ -79,7 +78,7 @@
         if (file->getLuaSupport() && !bRemoveLuaTags)
         {
             // Use the LuaState to replace the XML tags (calls our function)
-            boost::scoped_ptr<LuaState> luaState(new LuaState());
+            const std::unique_ptr<LuaState> luaState(new LuaState());
             luaState->setTraceMap(lineTrace);
             luaState->setIncludeParser(&Loader::replaceLuaTags);
             luaState->includeFile(file->getFilename());

Modified: code/branches/cpp11_v2/src/libraries/util/StringUtils.cc
===================================================================
--- code/branches/cpp11_v2/src/libraries/util/StringUtils.cc	2015-11-08 10:11:00 UTC (rev 10776)
+++ code/branches/cpp11_v2/src/libraries/util/StringUtils.cc	2015-11-08 10:16:22 UTC (rev 10777)
@@ -35,7 +35,6 @@
 
 #include <cctype>
 #include <ctime>
-#include <boost/scoped_array.hpp>
 #include "Convert.h"
 #include "Math.h"
 
@@ -481,7 +480,7 @@
     {
         size_t cols = str1.size() + 1;
         size_t rows = str2.size() + 1;
-        boost::scoped_array<int> matrix(new int[rows * cols]);
+        const std::unique_ptr<int[]> matrix(new int[rows * cols]);
 
         for (size_t r = 0; r < rows; ++r)
             for (size_t c = 0; c < cols; ++c)




More information about the Orxonox-commit mailing list