[Rcpp-commits] r4134 - in pkg/Rcpp: . inst/include/Rcpp/Benchmark src

noreply at r-forge.r-project.org noreply at r-forge.r-project.org
Mon Dec 10 16:44:33 CET 2012


Author: romain
Date: 2012-12-10 16:44:33 +0100 (Mon, 10 Dec 2012)
New Revision: 4134

Modified:
   pkg/Rcpp/ChangeLog
   pkg/Rcpp/inst/include/Rcpp/Benchmark/Timer.h
   pkg/Rcpp/src/Timer.cpp
Log:
move Timer into the Rcpp namespace

Modified: pkg/Rcpp/ChangeLog
===================================================================
--- pkg/Rcpp/ChangeLog	2012-12-10 15:37:39 UTC (rev 4133)
+++ pkg/Rcpp/ChangeLog	2012-12-10 15:44:33 UTC (rev 4134)
@@ -13,6 +13,7 @@
         * include/Rcpp/traits/traits.h: master file for all traits includes
         * include/Rcpp/macros/macros.h: master file for all macros includes
         * include/Rcpp/DataFrame.h: just have declaration for DataFrame
+        * include/Rcpp/Benchmark/Timer.h: move it into the Rcpp:: namespace
         
 2012-12-09 Romain Francois <romain at r-enthusiasts.com>
 

Modified: pkg/Rcpp/inst/include/Rcpp/Benchmark/Timer.h
===================================================================
--- pkg/Rcpp/inst/include/Rcpp/Benchmark/Timer.h	2012-12-10 15:37:39 UTC (rev 4133)
+++ pkg/Rcpp/inst/include/Rcpp/Benchmark/Timer.h	2012-12-10 15:44:33 UTC (rev 4134)
@@ -19,6 +19,9 @@
 // You should have received a copy of the GNU General Public License
 // along with Rcpp.  If not, see <http://www.gnu.org/licenses/>.
 
+#ifndef RCPP_BENCHMARH_TIMER_H
+#define RCPP_BENCHMARH_TIMER_H
+
 #include <stdint.h>
 #include <vector>
 #include <string>
@@ -27,7 +30,6 @@
 #include <Rinternals.h>
 
 namespace Rcpp{
-namespace Benchmark{
 
     typedef uint64_t nanotime_t;
     nanotime_t get_nanotime(void); 
@@ -50,5 +52,6 @@
     } ;
     
 }
-}
 
+#endif
+

Modified: pkg/Rcpp/src/Timer.cpp
===================================================================
--- pkg/Rcpp/src/Timer.cpp	2012-12-10 15:37:39 UTC (rev 4133)
+++ pkg/Rcpp/src/Timer.cpp	2012-12-10 15:44:33 UTC (rev 4134)
@@ -32,11 +32,10 @@
 #elif defined(sun) || defined(__sun) || defined(_AIX)
     #include <sys/time.h>
 #else /* Unsupported OS */
-    #error "Rcpp::Benchmark::Timer not supported by your OS."
+    #error "Rcpp::Timer not supported by your OS."
 #endif
 
 namespace Rcpp{
-namespace Benchmark{
      
       
 #if defined(_WIN32)   
@@ -118,5 +117,4 @@
         return out ;
     }
 }
-}
 



More information about the Rcpp-commits mailing list