|
Boost-Commit : |
Subject: [Boost-commit] svn:boost r66281 - sandbox/chrono/libs/chrono/example
From: vicente.botet_at_[hidden]
Date: 2010-10-30 12:26:35
Author: viboes
Date: 2010-10-30 12:26:32 EDT (Sat, 30 Oct 2010)
New Revision: 66281
URL: http://svn.boost.org/trac/boost/changeset/66281
Log:
Chrono: Cleanup
Removed:
sandbox/chrono/libs/chrono/example/function_stopclock_example.cpp
sandbox/chrono/libs/chrono/example/timex.cpp
Text files modified:
sandbox/chrono/libs/chrono/example/saturating.cpp | 2 +-
1 files changed, 1 insertions(+), 1 deletions(-)
Deleted: sandbox/chrono/libs/chrono/example/function_stopclock_example.cpp
==============================================================================
--- sandbox/chrono/libs/chrono/example/function_stopclock_example.cpp 2010-10-30 12:26:32 EDT (Sat, 30 Oct 2010)
+++ (empty file)
@@ -1,31 +0,0 @@
-// stopclock_example.cpp ---------------------------------------------------//
-
-// Copyright Beman Dawes 2006, 2008
-
-// Distributed under the Boost Software License, Version 1.0.
-// See http://www.boost.org/LICENSE_1_0.txt
-
-// See http://www.boost.org/libs/chrono for documentation.
-
-#include <boost/chrono/function_stopclock.hpp>
-#include <cmath>
-
-using namespace boost::chrono;
-int f1(long j)
-{
- function_stopclock<> _(BOOST_CURRENT_FUNCTION);
-
- for ( long i = 0; i < j; ++i )
- std::sqrt( 123.456L ); // burn some time
-
- return 0;
-}
-int main()
-{
- function_stopclock<> _(BOOST_CURRENT_FUNCTION);
-
- f1(1000);
- f1(2000);
- f1(3000);
- return 0;
-}
Modified: sandbox/chrono/libs/chrono/example/saturating.cpp
==============================================================================
--- sandbox/chrono/libs/chrono/example/saturating.cpp (original)
+++ sandbox/chrono/libs/chrono/example/saturating.cpp 2010-10-30 12:26:32 EDT (Sat, 30 Oct 2010)
@@ -70,7 +70,7 @@
saturate() : i_(nan) {}
explicit saturate(int_type i) : i_(i) {}
// explicit
- operator int_type() const;
+ operator int_type() const;
saturate& operator+=(saturate x);
saturate& operator-=(saturate x) {return *this += -x;}
Deleted: sandbox/chrono/libs/chrono/example/timex.cpp
==============================================================================
--- sandbox/chrono/libs/chrono/example/timex.cpp 2010-10-30 12:26:32 EDT (Sat, 30 Oct 2010)
+++ (empty file)
@@ -1,47 +0,0 @@
-// timex: timed execution program ------------------------------------------//
-
-// Copyright Beman Dawes 2007
-
-// Distributed under the Boost Software License, Version 1.0. (See accompanying
-// file LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt)
-
-// See http://www.boost.org/libs/system for documentation.
-
-#include <boost/chrono/stopclock.hpp>
-#include <cstdlib>
-#include <string>
-#include <iostream>
-
-int main( int argc, char * argv[] )
-{
- if ( argc == 1 )
- {
- std::cout << "invoke: timex [-v] command [args...]\n"
- " command will be executed and timings displayed\n"
- " -v option causes command and args to be displayed\n";
- return 1;
- }
-
- std::string s;
-
- bool verbose = false;
- if ( argc > 1 && *argv[1] == '-' && *(argv[1]+1) == 'v' )
- {
- verbose = true;
- ++argv;
- --argc;
- }
-
- for ( int i = 1; i < argc; ++i )
- {
- if ( i > 1 ) s += ' ';
- s += argv[i];
- }
-
- if ( verbose )
- { std::cout << "command: \"" << s.c_str() << "\"\n"; }
-
- boost::chrono::stopclock<> t;
-
- return std::system( s.c_str() );
-}
Boost-Commit list run by bdawes at acm.org, david.abrahams at rcn.com, gregod at cs.rpi.edu, cpdaniel at pacbell.net, john at johnmaddock.co.uk