|
Boost-Commit : |
Subject: [Boost-commit] svn:boost r63352 - in sandbox/chrono/libs/chrono/doc: . html html/boost_chrono html/boost_chrono/appendices html/boost_chrono/overview html/boost_chrono/reference html/boost_chrono/users_guide
From: vicente.botet_at_[hidden]
Date: 2010-06-26 11:18:54
Author: viboes
Date: 2010-06-26 11:18:46 EDT (Sat, 26 Jun 2010)
New Revision: 63352
URL: http://svn.boost.org/trac/boost/changeset/63352
Log:
Document Configuration macros
Text files modified:
sandbox/chrono/libs/chrono/doc/chrono.qbk | 546 +++++++++++++++++++++++++++------------
sandbox/chrono/libs/chrono/doc/html/boost_chrono/appendices.html | 2
sandbox/chrono/libs/chrono/doc/html/boost_chrono/appendices/acknowledgements.html | 23 +
sandbox/chrono/libs/chrono/doc/html/boost_chrono/appendices/faq.html | 46 +++
sandbox/chrono/libs/chrono/doc/html/boost_chrono/appendices/history.html | 9
sandbox/chrono/libs/chrono/doc/html/boost_chrono/appendices/perf.html | 4
sandbox/chrono/libs/chrono/doc/html/boost_chrono/appendices/rationale.html | 18
sandbox/chrono/libs/chrono/doc/html/boost_chrono/appendices/tests.html | 4
sandbox/chrono/libs/chrono/doc/html/boost_chrono/appendices/tickets.html | 139 +++++++--
sandbox/chrono/libs/chrono/doc/html/boost_chrono/appendices/todo.html | 4
sandbox/chrono/libs/chrono/doc/html/boost_chrono/overview.html | 49 +-
sandbox/chrono/libs/chrono/doc/html/boost_chrono/overview/motivation.html | 330 +++++++++++------------
sandbox/chrono/libs/chrono/doc/html/boost_chrono/reference/cpp0x.html | 524 ++++++++++++++++++++++++-------------
sandbox/chrono/libs/chrono/doc/html/boost_chrono/reference/other_clocks.html | 20
sandbox/chrono/libs/chrono/doc/html/boost_chrono/reference/stopwatch_reporters.html | 2
sandbox/chrono/libs/chrono/doc/html/boost_chrono/reference/stopwatches.html | 15
sandbox/chrono/libs/chrono/doc/html/boost_chrono/users_guide/ext_references.html | 5
sandbox/chrono/libs/chrono/doc/html/boost_chrono/users_guide/getting_started.html | 16
sandbox/chrono/libs/chrono/doc/html/boost_chrono/users_guide/tutorial.html | 8
sandbox/chrono/libs/chrono/doc/html/index.html | 2
20 files changed, 1120 insertions(+), 646 deletions(-)
Modified: sandbox/chrono/libs/chrono/doc/chrono.qbk
==============================================================================
--- sandbox/chrono/libs/chrono/doc/chrono.qbk (original)
+++ sandbox/chrono/libs/chrono/doc/chrono.qbk 2010-06-26 11:18:46 EDT (Sat, 26 Jun 2010)
@@ -8,7 +8,7 @@
/]
[article Boost.Chrono
- [quickbook 1.3]
+ [quickbook 1.4]
[authors [Hinnant, Howard]]
[authors [Dawes, Beman]]
[authors [Botet Escriba, Vicente J.]]
@@ -23,8 +23,74 @@
]
]
+[/==================]
[def __Boost_Chrono__ [*Boost.Chrono]]
+[/==================]
+[template clock_concept_link[link_text] [link boost_chrono.reference.cpp0x.chrono_chrono_hpp.clock [link_text]]]
+[def __clock_concept__ [clock_concept_link `Clock` concept]]
+[def __clock_concept_type__ [clock_concept_link `Clock`]]
+[def __clock_req__ [clock_concept_link `Clock` requirements]]
+
+[/==================]
+[template stopwatch_concept_link[link_text] [link boost_chrono.reference.stopwatches.stopwatch_req [link_text]]]
+[def __stopwatch_concept__ [stopwatch_concept_link `Stopwatch` concept]]
+[def __stopwatch_concept_type__ [stopwatch_concept_link `Stopwatch`]]
+[def __stopwatch_req__ [stopwatch_concept_link `Stopwatch` requirements]]
+
+[/==================]
+[template formatter_concept_link[link_text] [link boost_chrono.reference.formatters.formatter_req [link_text]]]
+[def __formatter_concept__ [formatter_concept_link `Formatter` concept]]
+[def __formatter_concept_type__ [formatter_concept_link `Formatter`]]
+[def __formatter_req__ [formatter_concept_link `Formatter` requirements]]
+
+[/==================]
+[/template duration_link[link_text] [link boost_chrono.reference.cpp0x.chrono_chrono_hpp.class_template__duration_ [link_text]]]
+[template duration_link[link_text] link_text]
+[def __duration__ [duration_link `duration`]]
+
+[/==================]
+[/template common_type_link[link_text] [link boost_chrono.reference.cpp0x.chrono_chrono_hpp.class_template__common_type_ [link_text]]]
+[template common_type_link[link_text] link_text]
+[def __common_type__ [duration_link __common_type__]]
+
+
+[/==================]
+[/template time_point_link[link_text] [link boost_chrono.reference.cpp0x.chrono_chrono_hpp.class_template__time_point_ [link_text]]]
+[template time_point_link[link_text] [link_text]]
+[def __time_point__ [time_point_link `time_point`]]
+
+[/==================]
+[/template system_clock_link[link_text] [link boost_chrono.reference.cpp0x.chrono_chrono_hpp.class__system_clock_ [link_text]]]
+[template system_clock_link[link_text] [link_text]]
+[def __system_clock__ [system_clock_link `system_clock`]]
+
+[/==================]
+[/template monotonic_clock_link[link_text] [link boost_chrono.reference.cpp0x.chrono_chrono_hpp.class__monotonic_clock_ [link_text]]]
+[template monotonic_clock_link[link_text] [link_text]]
+[def __monotonic_clock__ [monotonic_clock_link `monotonic_clock`]]
+
+[/==================]
+[/template high_resolution_clock_link[link_text] [link boost_chrono.reference.cpp0x.chrono_chrono_hpp.class__high_resolution_clock_ [link_text]]]
+[template high_resolution_clock_link[link_text] [link_text]]
+[def __high_resolution_clock__ [high_resolution_clock_link `high_resolution_clock`]]
+
+[/==================]
+[/template minutes_link[link_text] [link boost_chrono.reference.cpp0x.chrono_chrono_hpp.class__minutes_ [link_text]]]
+[template minutes_link[link_text] [link_text]]
+[def __minutes__ [minutes_link `minutes`]]
+
+[/==================]
+[/template nanoseconds_link[link_text] [link boost_chrono.reference.cpp0x.chrono_chrono_hpp.class__nanoseconds_ [link_text]]]
+[template nanoseconds_link[link_text] [link_text]]
+[def __nanoseconds__ [nanoseconds_link `nanoseconds`]]
+
+[/==================]
+[/template seconds_link[link_text] [link boost_chrono.reference.cpp0x.chrono_chrono_hpp.class__seconds_ [link_text]]]
+[template seconds_link[link_text] [link_text]]
+[def __seconds__ [seconds_link `seconds`]]
+
+
[/
[section Preface]
@@ -46,25 +112,25 @@
The __Boost_Chrono__ library provides:
-* One facility for representing time durations: `duration`. Examples of time durations include seconds, minutes and nanoseconds. All of these units of time duration are united with a generic interface by the duration facility.
-* One facility for representing points in time: `time_point`. A time_point represents an epoch plus or minus a duration. This paper leaves epochs unspecified. A time_point is associated with a clock.
-* Several clocks, some of which may not be available on any given platform: `system_clock`, `monotonic_clock` and `high_resolution_clock`. A clock is a symbolic bundle of a native `time_point` and `duration`, and a function which returns a `time_point` representing ['now].
+* One facility for representing time durations: __duration__. Examples of time durations include __seconds__, __minutes__ and __nanoseconds__. All of these units of time duration are united with a generic interface by the __duration__ facility.
+* One facility for representing points in time: __time_point__. A __time_point__ represents an epoch plus or minus a __duration__. The library leaves epochs unspecified. A __time_point__ is associated with a /clock/.
+* Several clocks, some of which may not be available on any given platform: __system_clock__, __monotonic_clock__ and __high_resolution_clock__. A clock is a symbolic bundle of a native __time_point__ and __duration__, and a function which returns a __time_point__ representing ['now].
-Additionally, a minimal amount of general purpose infrastructure is provided which will support both the interface and implementation of the clocks, time_points and durations proposed herein. It is expected that these general purpose facilities will also find utility in far ranging user applications as well.
+Additionally, a minimal amount of general purpose infrastructure is provided which will support both the interface and implementation of the /clocks/, __time_point__s and __duration__s proposed herein. It is expected that these general purpose facilities will also find utility in far ranging user applications as well.
-* common_type is a facility which is useful in specifying the type of the result of functions and operators which take a variety of types (e.g. "mixed mode" complex arithmetic).
+* __common_type__ is a facility which is useful in specifying the type of the result of functions and operators which take a variety of types (e.g. "mixed mode" complex arithmetic).
* ratio is a facility which is useful in specifying compile time rational constants. Compile time rational arithmetic is supported with protection against overflow and divide by zero. Such a facility is very handy when needing to efficiently represent 1/3 of a nanosecond, or specifying an inch in terms of meters (for example 254/10000 meters - which ratio will reduce to 127/5000 meters).
Knowing how long a program takes to execute is useful in both test and production environments. On top of the standard facilities __Boost_Chrono__ includes:
-* a Stopwatch middle layer: providing operations to start, stop, suspend or resume a `Stopwatch` to measure the elapsed time.
- * `Stopwatch` concept
- * Scoped helper classes allowing to pairwise start/stop operations, suspend/resume and resume/suspend a `Stopwatch`.
- * `stopwatch`, model of `Stopwatch` capturing elapsed Clock times.
- * `stopwatch_accumulator`, model of `Stopwatch` capturing cummulated elapsed Clock times.
+* a Stopwatch middle layer: providing operations to start, stop, suspend or resume a __Stopwatch__ to measure the elapsed time.
+ * __Stopwatch__ concept
+ * Scoped helper classes allowing to pairwise start/stop operations, suspend/resume and resume/suspend a __Stopwatch__.
+ * `stopwatch`, model of __Stopwatch__ capturing elapsed __Clock__ times.
+ * `stopwatch_accumulator`, model of __Stopwatch__ capturing cummulated elapsed Clock times.
-* a Stopclocks higher layer: provide a complete stopclock reporting package that can be invoked in a single line of code.
- * `stopwatch_reporter`, convenient reporting of models of Stopwatch results.
+* a Stopclocks higher layer: provide a complete stopclock reporting package that can be invoked in a single line of code.
+ * `stopwatch_reporter`, convenient reporting of models of __Stopwatch__ results.
* `stopclock<Clock>` shortcut of `stopwatch_reporter<stopwatch<Clock>>`
* Allows wide characters
@@ -79,14 +145,14 @@
[/
-
+
* Suspendible clock
- * `SuspendibleClock` concept
- * scope_suspend which do suspend/resume if the Clock is a model of SuspendibleClock concept, and nothing otherwise.
- * template class suspendible_clock<>
+ * __SuspendibleClock__ concept
+ * scope_suspend which do suspend/resume if the __Clock__ is a model of __SuspendibleClock__ concept, and nothing otherwise.
+ * template class `suspendible_clock<>`
]
-Last, __Boost_Chrono__ include typeof registration for classes `duration` and `time_point` so you can used auto emulated on C++03 compilers.
+Last, __Boost_Chrono__ include typeof registration for classes __duration__ and __time_point__ so you can used auto emulated on C++03 compilers.
[/====================================]
@@ -120,22 +186,22 @@
We all deal with time every day of our lives. We've intuitively known it since birth. Thus we are all very familiar with it and believe it to be a simple matter. The modeling of time in computer programs should be similarly simple.
-The unfortunate truth is that this perceived simplicity is only skin deep. Fortunately however, we do not need a terribly complicated solution to meet the bulk of our needs. However, overly simplistic solutions are fraught with danger, inherent inefficiency, and lack the ability to adapt as the computer industry evolves over decades.
+The unfortunate truth is that this perceived simplicity is only skin deep. Fortunately however, we do not need a terribly complicated solution to meet the bulk of our needs. However, overly simplistic solutions are fraught with danger, inherent inefficiency, and lack the ability to adapt as the computer industry evolves over decades.
__Boost_Chrono__ proposes a solution that is precision neutral, with a very simple end user interface which supports multiple clocks, multiple precisions (both coarser and finer than we will ever need), separate types for points in time and time durations, efficiency, and compile time enforced safety.
In addition to the clocks provided by the standard proposal, __Boost_Chrono__ provides specific process clocks and a thread clock.
-See [@http://www.open-std.org/jtc1/sc22/wg21/docs/papers/2008/n2661.htm [*N2661 - A Foundation to Sleep On]] which is very informative and provides motivation for key design decisions for `common_type`, `ratio` and `chrono`. This documentation contains a lot of extracts from this document.
+See [@http://www.open-std.org/jtc1/sc22/wg21/docs/papers/2008/n2661.htm [*N2661 - A Foundation to Sleep On]] which is very informative and provides motivation for key design decisions for __common_type__, `ratio` and `chrono`. This documentation contains a lot of extracts from this document.
[section Common type]
-`common_type` has been a recurring theme in many places for many years. We've previously known it as promote and examples of it are spread throughout boost. It has been reinvented independently several times, because it is so useful.
+__common_type__ has been a recurring theme in many places for many years. We've previously known it as promote and examples of it are spread throughout boost. It has been reinvented independently several times, because it is so useful.
-Andrei Alexandrescu recently pointed us at a D library: std.traits - D Programming Language - Digital Mars, which became the motivation for this particular name, and the variadic nature of this trait.
+Andrei Alexandrescu recently pointed us at a D library: std.traits - D Programming Language - Digital Mars, which became the motivation for this particular name, and the variadic nature of [@http://www.digitalmars.com/d/2.0/phobos/std_traits.html#CommonType this trait].
-In a nutshell, `common_type` is a trait that takes 1 or more types, and returns a type which all of the types will convert to. The default definition demands this conversion be implicit. However the trait can be specialized for user-defined types which want to limit their inter-type conversions to explicit, and yet still want to interoperate with the `common_type` facility.
+In a nutshell, __common_type__ is a trait that takes 1 or more types, and returns a type which all of the types will convert to. The default definition demands this conversion be implicit. However the trait can be specialized for user-defined types which want to limit their inter-type conversions to explicit, and yet still want to interoperate with the __common_type__ facility.
[*Example:]
@@ -143,7 +209,7 @@
typename common_type<complex<T>, complex<U> >::type
operator+(complex<T>, complex<U>);
-In the above example, "mixed-mode" complex arithmetic is allowed. The return type is described by `common_type`. For example the resulting type of adding a `complex<int>` and `complex<double>` might be a `complex<double>`. Another choice for the author might be:
+In the above example, "mixed-mode" complex arithmetic is allowed. The return type is described by __common_type__. For example the resulting type of adding a `complex<int>` and `complex<double>` might be a `complex<double>`. Another choice for the author might be:
template <class T, class U>
complex<typename common_type<T, U>::type>
@@ -155,14 +221,14 @@
typename common_type<T...>::type
min(T... t);
-This is a very useful and broadly applicable utility. The `duration` and `time_point` facilities use it to make multi-precision arithmetic seamless and exact.
+This is a very useful and broadly applicable utility. The __duration__ and __time_point__ facilities use it to make multi-precision arithmetic seamless and exact.
[endsect]
[section Ratio]
-`ratio` is a general purpose utility inspired by Walter Brown allowing one to easily and safely compute rational values at compile time. The `ratio` class catches all errors (such as divide by zero and overflow) at compile time. It is used in the `duration` and `time_point` classes to efficiently create units of time. It can also be used in other "quantity" libraries (both std-defined and user-defined), or anywhere there is a rational constant which is known at compile time. The use of this utility can greatly reduce the chances of run time overflow because the `ratio` (and any ratios resulting from `ratio` arithmetic) are always reduced to lowest terms.
+`ratio` is a general purpose utility inspired by Walter Brown allowing one to easily and safely compute rational values at compile time. The `ratio` class catches all errors (such as divide by zero and overflow) at compile time. It is used in the __duration__ and __time_point__ classes to efficiently create units of time. It can also be used in other "quantity" libraries (both std-defined and user-defined), or anywhere there is a rational constant which is known at compile time. The use of this utility can greatly reduce the chances of run time overflow because the `ratio` (and any ratios resulting from `ratio` arithmetic) are always reduced to lowest terms.
`ratio` is a template taking two intmax_ts, with the second defaulted to 1. In addition to copy constructors and assignement, it only has two public members, both of which are static const intmax_t. One is the numerator of the `ratio` and the other is the denominator. The `ratio` is always normalized such that it is expressed in lowest terms, and the denominator is always positive. When the numerator is 0, the denominator is always 1.
@@ -184,38 +250,38 @@
[section Duration]
-The `duration` is the heart of this library. The interface that the user will see in everyday use is nearly identical to that of Boost.DateTime time `duration`s authored by Jeff Garland, both in syntax and in behavior. This has been a very popular boost library for 7 years. There is an enormous positive history with this interface.
+The __duration__ is the heart of this library. The interface that the user will see in everyday use is nearly identical to that of Boost.DateTime time __duration__s authored by Jeff Garland, both in syntax and in behavior. This has been a very popular boost library for 7 years. There is an enormous positive history with this interface.
-The library consists of six units of time `duration`:
+The library consists of six units of time __duration__:
* `hours`
-* `minutes`
-* `seconds`
+* __minutes__
+* __seconds__
* `milliseconds`
* `microseconds`
-* `nanoseconds`
+* __nanoseconds__
These units were chosen as a subset of the boost library because they are the most common units used when sleeping, waiting on a condition variable, or waiting to obtain the lock on a mutex. Each of these units is nothing but a thin wrapper around a signed integral count. That is, when you construct `minutes(3)`, all that happens is a `3` is stored inside of minutes. When you construct `microseconds(3)`, all that happens is a `3` is stored inside of microseconds.
-The only context in which these different types differ is when being converted to one another. At this time, unit-specific compile-time conversion constants are used to convert the source unit to the target unit. Only conversions from coarser units to finer units are allowed (in boost). This restriction ensures that all conversions are always exact. That is, `microseconds` can always represent any value `minutes` has.
+The only context in which these different types differ is when being converted to one another. At this time, unit-specific compile-time conversion constants are used to convert the source unit to the target unit. Only conversions from coarser units to finer units are allowed (in boost). This restriction ensures that all conversions are always exact. That is, `microseconds` can always represent any value __minutes__ has.
-In Boost.DateTime, these units are united via inheritance. __Boost_Chrono__ instead unites these units through the class template `duration`. That is, in __Boost_Chrono__ all six of the above units are nothing but typedefs to different instantiations of `duration`. This change from Boost.DateTime has a far reaching positive impact, while not changing the syntax of the everyday use at all.
+In Boost.DateTime, these units are united via inheritance. __Boost_Chrono__ instead unites these units through the class template __duration__. That is, in __Boost_Chrono__ all six of the above units are nothing but typedefs to different instantiations of __duration__. This change from Boost.DateTime has a far reaching positive impact, while not changing the syntax of the everyday use at all.
-The most immediate positive impact is that the library can immediately generate any unit, any precision it needs. This is sometimes necessary when doing comparisons or arithmetic between `duration`s of differing precision, assuming one wants the comparison and arithmetic to be exactly correct.
+The most immediate positive impact is that the library can immediately generate any unit, any precision it needs. This is sometimes necessary when doing comparisons or arithmetic between __duration__s of differing precision, assuming one wants the comparison and arithmetic to be exactly correct.
-A secondary benefit is that by publishing the class template `duration` interface, user code can very easily create `duration`s with any precision they desire. The `ratio` utility is used to specify the precision, so as long as the precision can be expressed by a rational constant with respect to seconds, this framework can exactly represent it (one third of a second is no problem, and neither is one third of a `femto` second). All of this utility and flexibility comes at no cost just by making use of the no-run-time-overhead `ratio` facility.
+A secondary benefit is that by publishing the class template __duration__ interface, user code can very easily create __duration__s with any precision they desire. The `ratio` utility is used to specify the precision, so as long as the precision can be expressed by a rational constant with respect to seconds, this framework can exactly represent it (one third of a second is no problem, and neither is one third of a `femto` second). All of this utility and flexibility comes at no cost just by making use of the no-run-time-overhead `ratio` facility.
-In Boost.DateTime, `hours` does not have the same representation as `nanoseconds`. The former is usually represented with a `long` whereas a `long long` is required for the latter. The reason for this is simply range. You don't need many hours to cover an extremely large range of time. But this isn't true of nanoseconds. Being able to reduce the sizeof overhead for some units when possible, can be a significant performance advantage.
+In Boost.DateTime, `hours` does not have the same representation as __nanoseconds__. The former is usually represented with a `long` whereas a `long long` is required for the latter. The reason for this is simply range. You don't need many hours to cover an extremely large range of time. But this isn't true of nanoseconds. Being able to reduce the sizeof overhead for some units when possible, can be a significant performance advantage.
-__Boost_Chrono__ continues, and generalizes that philosophy. Not only can one specify the precision of a `duration`, one can also specify its representation. This can be any integral type, or even a floating point type. Or it can be a user-defined type which emulates an arithmetic type. The six predefined units all use signed integral types as their representation. And they all have a minimum range of +/- 292 years. `nanoseconds` needs 64 bits to cover that range. `hours` needs only 23 bits to cover that range.
+__Boost_Chrono__ continues, and generalizes that philosophy. Not only can one specify the precision of a __duration__, one can also specify its representation. This can be any integral type, or even a floating point type. Or it can be a user-defined type which emulates an arithmetic type. The six predefined units all use signed integral types as their representation. And they all have a minimum range of +/- 292 years. __nanoseconds__ needs 64 bits to cover that range. `hours` needs only 23 bits to cover that range.
-[heading So What Exactly is a `duration` and How Do I Use One?]
+[heading So What Exactly is a __duration__ and How Do I Use One?]
-A `duration` has a representation and a tick period (precision).
+A __duration__ has a representation and a tick period (precision).
template <class Rep, class Period = ratio<1> > class duration;
-The representation is simply any arithmetic type, or an emulation of such a type. The representation stores a count of ticks. This count is the only data member stored in a `duration`. If the representation is floating point, it can store fractions of a tick to the precision of the representation. The tick period is represented by a `ratio` and is encoded into the `duration`'s type, instead of stored. The tick period only has an impact on the behavior of the `duration` when a conversion between different `duration`'s is attempted. The tick period is completely ignored when simply doing arithmetic among like `duration`s.
+The representation is simply any arithmetic type, or an emulation of such a type. The representation stores a count of ticks. This count is the only data member stored in a __duration__. If the representation is floating point, it can store fractions of a tick to the precision of the representation. The tick period is represented by a `ratio` and is encoded into the __duration__'s type, instead of stored. The tick period only has an impact on the behavior of the __duration__ when a conversion between different __duration__'s is attempted. The tick period is completely ignored when simply doing arithmetic among like __duration__s.
[*Example:]
@@ -233,13 +299,13 @@
In the final line of code above, there is an implicit conversion from minutes to microseconds, resulting in a relatively large number of microseconds.
-If you need to access the tick count within a `duration`, there is a member `count()` which simply returns the stored tick count.
+If you need to access the tick count within a __duration__, there is a member `count()` which simply returns the stored tick count.
long long tc = us4.count(); // tc is 300000005
-These `duration`s have very simple, very predictable, and very observable behavior. After all, this is really nothing but the time tested interface of Jeff's boost time `duration` library (unified with templates instead of inheritance).
+These __duration__s have very simple, very predictable, and very observable behavior. After all, this is really nothing but the time tested interface of Jeff's boost time __duration__ library (unified with templates instead of inheritance).
-[heading What happens if I assign `m3 + us3` to `minutes` instead of `microseconds`?]
+[heading What happens if I assign `m3 + us3` to __minutes__ instead of `microseconds`?]
minutes m4 = m3 + us3;
@@ -251,9 +317,9 @@
minutes m4 = duration_cast<minutes>(m3 + us3); // m4.count() == 5
-In general, one can perform `duration` arithmetic at will. If `duration_cast` isn't used, and it compiles, the arithmetic is exact. Any place one wants to override this exact arithmetic behavior, duration_cast can be used to explicitly specify that desire. The `duration_cast` has the same efficiency as the implicit conversion, and will even be exact as often as it can.
+In general, one can perform __duration__ arithmetic at will. If `duration_cast` isn't used, and it compiles, the arithmetic is exact. Any place one wants to override this exact arithmetic behavior, duration_cast can be used to explicitly specify that desire. The `duration_cast` has the same efficiency as the implicit conversion, and will even be exact as often as it can.
-[heading I'm trafficking in floating point `duration`s. I don't want to deal with writing `duration_cast` all over the place. I'm content with the precision of my floating point representation]
+[heading I'm trafficking in floating point __duration__s. I don't want to deal with writing `duration_cast` all over the place. I'm content with the precision of my floating point representation]
Not a problem. When the destination of a conversion has floating point representation, all conversions are allowed to happen implicitly.
@@ -264,11 +330,11 @@
If you were writing these conversions by hand, you could not make it more efficient. The use of `ratio` ensures that all conversion constants are simplified as much as possible at compile time. This usually results in the numerator or denominator of the conversion factor simplifying to `1`, and being subsequently ignored in converting the run time values of the tick counts.
-[heading How complicated is it to build a function taking a `duration` parameter?]
+[heading How complicated is it to build a function taking a __duration__ parameter?]
There are several options open to the user:
-* If the author of the function wants to accept any `duration`, and is willing to work in floating point `duration`s, he can simply use any floating point `duration` as the parameter:
+* If the author of the function wants to accept any __duration__, and is willing to work in floating point __duration__s, he can simply use any floating point __duration__ as the parameter:
void f(duration<double> d) // accept floating point seconds
{
@@ -277,7 +343,7 @@
f(microseconds(3));
-* If the author of the function wants to traffic only in integral `duration`s, and is content with handling nothing finer than say nanoseconds (just as an example), he can simply specify nanoseconds as the parameter:
+* If the author of the function wants to traffic only in integral __duration__s, and is content with handling nothing finer than say nanoseconds (just as an example), he can simply specify nanoseconds as the parameter:
void f(nanoseconds d)
{
@@ -286,16 +352,16 @@
f(microseconds(3));
-In this design, if the client wants to pass in a floating point `duration`, or a `duration` of finer precision than nanoseconds, then the client is responsible for choosing his own rounding mode in the conversion to nanoseconds.
+In this design, if the client wants to pass in a floating point __duration__, or a __duration__ of finer precision than nanoseconds, then the client is responsible for choosing his own rounding mode in the conversion to nanoseconds.
duration<double> s(1./3); // 1/3 of a second
f(duration_cast<nanoseconds>(s)); // round towards zero in conversion to nanoseconds
-In the example above, the client of f has chosen "round towards zero" as the desired rounding mode to nanoseconds. If the client has a `duration` that won't exactly convert to nanoseconds, and fails to choose how the conversion will take place, the compiler will refuse the call:
+In the example above, the client of f has chosen "round towards zero" as the desired rounding mode to nanoseconds. If the client has a __duration__ that won't exactly convert to nanoseconds, and fails to choose how the conversion will take place, the compiler will refuse the call:
f(s); // does not compile
-* If the author of the function wants to accept any `duration`, but wants to work with integral representations and wants to control the rounding mode internally, then he can template the function:
+* If the author of the function wants to accept any __duration__, but wants to work with integral representations and wants to control the rounding mode internally, then he can template the function:
template <class Rep, class Period>
void f(duration<Rep, Period> d)
@@ -309,7 +375,7 @@
f(duration<double>(1./3));
-* If the author in the example does not want to accept floating point based `duration`s, he can enforce that behavior like so:
+* If the author in the example does not want to accept floating point based __duration__s, he can enforce that behavior like so:
template <class Period>
void f(duration<long long, Period> d)
@@ -323,21 +389,21 @@
f(duration<long long, pico>(333333333333)); // About 1/3 of a second worth of picoseconds
-Clients with floating point `duration`s who want to use f will now have to convert to an integral `duration` themselves before passing the result to f.
+Clients with floating point __duration__s who want to use f will now have to convert to an integral __duration__ themselves before passing the result to f.
-In summary, the author of f has quite a bit of flexibility and control in the interface he wants to provide his clients with, and easy options for manipulating that `duration` internal to his function.
+In summary, the author of f has quite a bit of flexibility and control in the interface he wants to provide his clients with, and easy options for manipulating that __duration__ internal to his function.
[endsect]
[section Clocks]
-While `duration`s only have precision and representation to concern themselves, clocks and `time_point`s are intimately related and refer to one another. Because clocks are simpler to explain, we will do so first without fully explaining `time_point`s. Once clocks are introduced, it will be easier to then fill in what a `time_point` is.
+While __duration__s only have precision and representation to concern themselves, clocks and __time_point__s are intimately related and refer to one another. Because clocks are simpler to explain, we will do so first without fully explaining __time_point__s. Once clocks are introduced, it will be easier to then fill in what a __time_point__ is.
A clock is a concept which bundles 3 things:
-# A concrete `duration` type.
-# A concrete `time_point` type.
-# A function called now() which returns the concrete `time_point`.
+# A concrete __duration__ type.
+# A concrete __time_point__ type.
+# A function called now() which returns the concrete __time_point__.
__Boost_Chrono__ provides the standard concrete clocks:
@@ -364,42 +430,42 @@
Clock::time_point t1 = Clock::now();
-And one can get the time `duration` between two `time_point`s associated with Clock with:
+And one can get the time __duration__ between two __time_point__s associated with Clock with:
Clock::duration d = t1 - Clock::now();
-And one can specify a past or future `time_point` with:
+And one can specify a past or future __time_point__ with:
Clock::time_point t2 = Clock::now() + d;
-Note how even if a particular clock becomes obsolete, the next clock in line will have the same API. There is no new learning curve to come up. The only source code changes will be simply changing the type of the clock. The same `duration` and `time_point` framework continues to work as new clocks are introduced. And multiple clocks are safely and easily handled within the same program.
+Note how even if a particular clock becomes obsolete, the next clock in line will have the same API. There is no new learning curve to come up. The only source code changes will be simply changing the type of the clock. The same __duration__ and __time_point__ framework continues to work as new clocks are introduced. And multiple clocks are safely and easily handled within the same program.
[endsect]
[section Time Point]
-A `time_point` represents a point in time, as opposed to a `duration` of time. Another way of saying the same thing, is that a `time_point` represents an epoch plus or minus a `duration`. Examples of `time_point`s include:
+A __time_point__ represents a point in time, as opposed to a __duration__ of time. Another way of saying the same thing, is that a __time_point__ represents an epoch plus or minus a __duration__. Examples of __time_point__s include:
* 3 minutes after the computer booted.
* 03:14:07 UTC on Tuesday, January 19, 2038
* 20 milliseconds after I started that timer.
-In each of the examples above, a different epoch is implied. Sometimes an epoch has meaning for several millennia. Other times the meaning of an epoch is lost after a while (such as the start of a timer, or when the computer booted). However, if two `time_point`s are known to share the same epoch, they can be subtracted, yielding a valid `duration`, even if the definition of the epoch no longer has meaning.
+In each of the examples above, a different epoch is implied. Sometimes an epoch has meaning for several millennia. Other times the meaning of an epoch is lost after a while (such as the start of a timer, or when the computer booted). However, if two __time_point__s are known to share the same epoch, they can be subtracted, yielding a valid __duration__, even if the definition of the epoch no longer has meaning.
-In __Boost_Chrono__, an epoch is a purely abstract and unspecified concept. There is no type representing an epoch. It is simply an idea that relates (or doesn't) `time_point`s to a clock, and in the case that they share a clock, `time_point`s to one another. `time_point`s associated with different clocks are generally not interoperable unless the relationship between the epochs associated with each clock is known.
+In __Boost_Chrono__, an epoch is a purely abstract and unspecified concept. There is no type representing an epoch. It is simply an idea that relates (or doesn't) __time_point__s to a clock, and in the case that they share a clock, __time_point__s to one another. __time_point__s associated with different clocks are generally not interoperable unless the relationship between the epochs associated with each clock is known.
-[heading So What Exactly is a `time_point` and How Do I Use One?]
+[heading So What Exactly is a __time_point__ and How Do I Use One?]
-A `time_point` has a clock and a `duration`.
+A __time_point__ has a clock and a __duration__.
template <class Clock, class Duration = typename Clock::duration> class time_point;
-The `time_point`'s clock is not stored. It is simply embedded into the `time_point`'s type and serves two purposes:
+The __time_point__'s clock is not stored. It is simply embedded into the __time_point__'s type and serves two purposes:
-# Because `time_point`s originating from different clocks have different types, the compiler can be instructed to fail if incompatible `time_point`s are used in inappropriate ways.
-# Given a `time_point`, one often needs to compare that `time_point` to "now". This is very simple as long as the `time_point` knows what clock it is defined with respect to.
+# Because __time_point__s originating from different clocks have different types, the compiler can be instructed to fail if incompatible __time_point__s are used in inappropriate ways.
+# Given a __time_point__, one often needs to compare that __time_point__ to "now". This is very simple as long as the __time_point__ knows what clock it is defined with respect to.
-A `time_point`'s `duration` is stored as the only data member of the `time_point`. Thus `time_point`s and their corresponding `duration` have exactly the same layout. But they have very different meanings. For example, it is one thing to say I want to sleep for 3 minutes. It is a completely different thing to say I want to sleep until 3 minutes past the time I started that timer (unless you just happened to start that timer now). Both meanings (and options for sleeping) have great practical value in common use cases for sleeping, waiting on a condition variable, and waiting for a mutex's lock. These same concepts and tools are found (for example) in Ada.
+A __time_point__'s __duration__ is stored as the only data member of the __time_point__. Thus __time_point__s and their corresponding __duration__ have exactly the same layout. But they have very different meanings. For example, it is one thing to say I want to sleep for 3 minutes. It is a completely different thing to say I want to sleep until 3 minutes past the time I started that timer (unless you just happened to start that timer now). Both meanings (and options for sleeping) have great practical value in common use cases for sleeping, waiting on a condition variable, and waiting for a mutex's lock. These same concepts and tools are found (for example) in Ada.
A timer example:
@@ -412,7 +478,7 @@
cout << "f() took " << sec.count() << " seconds\n";
}
-Note that if one is using the `duration` between two clock `time_point`s in a way where the precision of the `duration` matters, it is good practice to convert the clock's native `duration` to a known `duration`. This insulates the code from future changes which may be made to the clock's native precision in the future. For example monotonic_clock could easily be based on the clock speed of the cpu. When you upgrade to a faster machine, you do not want your code that assumed a certain tick period of this clock to start experiencing run time failures because your timing code has silently changed meaning.
+Note that if one is using the __duration__ between two clock __time_point__s in a way where the precision of the __duration__ matters, it is good practice to convert the clock's native __duration__ to a known __duration__. This insulates the code from future changes which may be made to the clock's native precision in the future. For example monotonic_clock could easily be based on the clock speed of the cpu. When you upgrade to a faster machine, you do not want your code that assumed a certain tick period of this clock to start experiencing run time failures because your timing code has silently changed meaning.
A delay loop example:
@@ -530,15 +596,15 @@
* Precission of your clock. If the precission of your clock is 10ms you can not be able to measure the time spent by blocks of code that takes the same order of magnitude. The library provides a hig_resolution_clock that gives you the higher resolution available on your platform. Respect to the precission, nothing to do except to take the clock with the highest resolution and measures blocks of code that will spent time having more than one order of magnitude the precission of the clock.
-```
+``
#include <boost/chrono/chrono.hpp>
...
stopclock<high_resolution_clock> _;
-```
+``
* When your application is multithreaded, and you use a process clock, the time you get is the delay during which your block has been executed, in concurrency with the other threads of execution. If what you want is the time spent by this specific thread another clock is needed. The library provide a `thread_clock` that returns the time spent by the thread on platforms providing this kind of data. It can be used as follows
-```
+``
#include <boost/chrono/thread_clock.hpp>
...
#if defined(BOOST_CHRONO_HAS_THREAD_CLOCK)
@@ -546,7 +612,7 @@
#else
stopclock<process_real_cpu_clock> _;
#endif
-```
+``
* Nested stopclocks (usually nested function calls where each function contains a stopclock). When the nesting is deep enough, the cumulative overhead of all the stopclock functionality make the data unreliable except for the inner-most trace points. The question is, how much time is related to the application code we want to measure and how much to the fact we are meassuring and logging in inner blocks?
@@ -591,7 +657,7 @@
You can get the last stable release of __Boost_Chrono__ by downloading [^chrono.zip] from the
[@http://www.boost-consulting.com/vault/index.php?directory=System Boost Vault]
-You can also access the latest (unstable?) state from the [@https://svn.boost.org/svn/boost/sandbox/chrono Boost Sandbox]. Just go to [@http://svn.boost.org/trac/boost/wiki/BoostSubversion here] and follow the instructions there for anonymous SVN access.
+You can also access the latest (unstable?) state from the [@https://svn.boost.org/svn/boost/sandbox/chrono Boost Sandbox]. Just go to [@http://svn.boost.org/trac/boost/wiki/BoostSubversion here] and follow the instructions there for anonymous SVN access.
[/==========================================]
[heading Where to install __Boost_Chrono__? ]
@@ -757,7 +823,7 @@
[section How to get the common type of inter-type with explicit conversions?]
-The default definition of `common_type` demands the conversion be implicit. However the trait can be specialized for user-defined types which want to limit their inter-type conversions to explicit, and yet still want to interoperate with the `common_type` facility.
+The default definition of __common_type__ demands the conversion be implicit. However the trait can be specialized for user-defined types which want to limit their inter-type conversions to explicit, and yet still want to interoperate with the __common_type__ facility.
@@ -771,7 +837,7 @@
[section How to get the actual CPU milliseconds (or other units?) used by the current thread between end and start?]
-
+
You can use `duration_cast<>` to convert the `thread_clock::duration` into whatever units you desire. This facility will round down (truncate) if an exact conversion is not possible. Ex:
typedef boost::chrono::milliseconds ms;
@@ -781,7 +847,7 @@
std::cout << ms.count() << "ms\n";
-As `boost::chrono::thread_clock::duration` is nanoseconds, we can convert to `nanoseconds`, or some integral-based duration which `nanoseconds` will always exactly convert to, then `duration_cast<>` is unnecessary:
+As `boost::chrono::thread_clock::duration` is nanoseconds, we can convert to __nanoseconds__, or some integral-based duration which __nanoseconds__ will always exactly convert to, then `duration_cast<>` is unnecessary:
typedef boost::chrono::nanoseconds ns;
ns d = end - start;
@@ -1444,7 +1510,7 @@
[/==================]
[section Cycle count]
-Users can easily create their own clocks, with both points in time and time durations which have a representation and precision of their own choosing. For example if there is a hardware counter which simply increments a count with each cycle of the cpu, one can very easily build clocks, time points and durations on top of that, using only a few tens of lines of code. Such systems can be used to call the time-sensitive threading API's such as sleep, wait on a condition variable, or wait for a mutex lock. The API proposed herein is not sensitive as to whether this is a 300MHz clock (with a 3 1/3 nanosecond tick period) or a 3GHz clock (with a tick period of 1/3 of a nanosecond). And the resulting code will be just as efficient as if the user wrote a special purpose clock cycle counter.
+Users can easily create their own clocks, with both points in time and time durations which have a representation and precision of their own choosing. For example if there is a hardware counter which simply increments a count with each cycle of the cpu, one can very easily build clocks, time points and durations on top of that, using only a few tens of lines of code. Such systems can be used to call the time-sensitive threading API's such as sleep, wait on a condition variable, or wait for a mutex lock. The API proposed herein is not sensitive as to whether this is a 300MHz clock (with a 3 1/3 nanosecond tick period) or a 3GHz clock (with a tick period of 1/3 of a nanosecond). And the resulting code will be just as efficient as if the user wrote a special purpose clock cycle counter.
#include <boost/chrono/chrono.hpp>
@@ -2156,6 +2222,12 @@
[From Vicente Juan Botet Escriba.]
]
+[
+ [[@http://www.digitalmars.com/d/2.0/phobos/std_traits.html#CommonType D programming language - CommonType trait]]
+ [From Andrei Alexandrescu.]
+]
+
+
]
[endsect]
@@ -2172,13 +2244,41 @@
[section:common_type_hpp Header `<boost/type_traits/common_type.hpp>`]
[/===================================================================]
+ #define BOOST_COMMON_TYPE_ARITY
+ #define BOOST_COMMON_TYPE_USES_STATIC_ASSERT
+ #define BOOST_COMMON_TYPE_USES_MPL_ASSERT
+ #define BOOST_COMMON_TYPE_USES_ARRAY_ASSERT
+
+ #define BOOST_COMMON_TYPE_MUST_BE_A_COMPLE_TYPE
+
namespace boost {
template <class ...T> struct common_type;
}
-[section:common_type Class Template `common_type`]
+[section:macros Configuration macros]
+
+When BOOST_NO_VARIADIC_TEMPLATES is defined BOOST_COMMON_TYPE_ARITY gives the maximum number of template parameters for __common_type__.
+
+When BOOST_NO_STATIC_ASSERT is defined, the user can select the way static assertions are reported. Define
+
+* BOOST_COMMON_TYPE_USES_STATIC_ASSERT: define it if you want to use Boost.StaticAssert
+* BOOST_COMMON_TYPE_USES_MPL_ASSERT: define it if you want to use Boost.MPL static asertions
+* BOOST_COMMON_TYPE_USES_ARRAY_ASSERT: define it if you want to use internal static asertions
+* nothing if you don't want static asertions
+
+When BOOST_COMMON_TYPE_USES_MPL_ASSERT is not defined the following symbols are defined as
+
+ #define BOOST_COMMON_TYPE_MUST_BE_A_COMPLE_TYPE \
+ "must be complete type"
-`common_type` is a facility which is useful in specifying the type of the result of functions and operators which take a variety of types (e.g. "mixed mode" complex arithmetic).
+Depending on the static assertion used system you will have an hint of the failing assertion either through the symbol or through the texte.
+
+
+[endsect]
+
+[section:common_type Class Template __common_type__]
+
+__common_type__ is a facility which is useful in specifying the type of the result of functions and operators which take a variety of types (e.g. "mixed mode" complex arithmetic).
The nested typedef `common_type::type` could be defined as follows:
@@ -2204,7 +2304,7 @@
All parameter types must be complete. This trait is permitted to be specialized by a user if at least one template parameter is a user-defined type.
-[*Note:] Such specializations are required when only explicit conversions are desired among the `common_type` arguments.
+[*Note:] Such specializations are required when only explicit conversions are desired among the __common_type__ arguments.
[endsect]
@@ -2218,6 +2318,19 @@
`ratio` is a facility which is useful in specifying compile time rational constants. Compile time rational arithmetic is supported with protection against overflow and divide by zero. Such a facility is very handy when needing to efficiently represent 1/3 of a nanosecond, or specifying an inch in terms of meters (for example 254/10000 meters - which `ratio` will reduce to 127/5000 meters).
+ #define BOOST_RATIO_USES_STATIC_ASSERT
+ #define BOOST_RATIO_USES_MPL_ASSERT
+ #define BOOST_RATIO_USES_ARRAY_ASSERT
+
+ #define BOOST_RATIO_OVERFLOW_IN_ADD
+ #define BOOST_RATIO_OVERFLOW_IN_ADD
+ #define BOOST_RATIO_OVERFLOW_IN_SUB
+ #define BOOST_RATIO_OVERFLOW_IN_MUL
+ #define BOOST_RATIO_OVERFLOW_IN_DIV
+ #define BOOST_RATIO_RATIO_NUMERATOR_IS_OUT_OF_RANGE
+ #define BOOST_RATIO_RATIO_DIVIDE_BY_0
+ #define BOOST_RATIO_RATIO_DENOMINATOR_IS_OUT_OF_RANGE
+
namespace boost {
template <boost::intmax_t N, boost::intmax_t D = 1> class ratio;
@@ -2256,6 +2369,30 @@
}
+[section:macros Configuration macros]
+
+When BOOST_NO_STATIC_ASSERT is defined, the user can select the way static assertions are reported. Define
+
+* BOOST_RATIO_USES_STATIC_ASSERT: define it if you want to use Boost.StaticAssert
+* BOOST_RATIO_USES_MPL_ASSERT: define it if you want to use Boost.MPL static asertions
+* BOOST_RATIO_USES_ARRAY_ASSERT: define it if you want to use internal static asertions
+* nothing if you don't want static asertions
+
+When BOOST_RATIO_USES_MPL_ASSERT is not defined the following symbols are defined as
+
+ #define BOOST_RATIO_OVERFLOW_IN_ADD "overflow in ratio add"
+ #define BOOST_RATIO_OVERFLOW_IN_ADD "overflow in ratio add"
+ #define BOOST_RATIO_OVERFLOW_IN_SUB "overflow in ratio sub"
+ #define BOOST_RATIO_OVERFLOW_IN_MUL "overflow in ratio mul"
+ #define BOOST_RATIO_OVERFLOW_IN_DIV "overflow in ratio div"
+ #define BOOST_RATIO_RATIO_NUMERATOR_IS_OUT_OF_RANGE "ratio numerator is out of range"
+ #define BOOST_RATIO_RATIO_DIVIDE_BY_0 "ratio divide by 0"
+ #define BOOST_RATIO_RATIO_DENOMINATOR_IS_OUT_OF_RANGE "ratio denominator is out of range"
+
+Depending on the static assertion used system you will have an hint of the failing assertion either through the symbol or through the texte.
+
+[endsect]
+
[section:ratio Class Template `ratio<>`]
template <boost::intmax_t N, boost::intmax_t D>
@@ -2427,9 +2564,16 @@
[section:chrono_chrono_hpp Header `<boost/chrono/chrono.hpp>`]
[/=============================================]
- #define BOOST_SYSTEM_CLOCK_DURATION
#define BOOST_CHRONO_HAS_CLOCK_MONOTONIC
+ #define BOOST_CHRONO_A_DURATION_REPRESENTATION_CAN_NOT_BE_A_DURATION \
+ "A duration representation can not be a duration"
+ #define BOOST_CHRONO_SECOND_TEMPLATE_PARAMETER_OF_DURATION_MUST_BE_A_STD_RATIO \
+ "Second template parameter of duration must be a std::ratio"
+ #define BOOST_CHRONO_DURATION_PERIOD_MUST_BE_POSITIVE \
+ "duration period must be positive"
+ #define BOOST_CHRONO_SECOND_TEMPLATE_PARAMETER_OF_TIME_POINT_MUST_BE_A_BOOST_CHRONO_DURATION \
+
namespace boost {
namespace chrono {
@@ -2559,26 +2703,52 @@
}
}
+
+[section:macros Configuration macros]
+
+
+When BOOST_NO_STATIC_ASSERT is defined, the user can select the way static assertions are reported. Define
+
+* BOOST_CHRONO_USES_STATIC_ASSERT: define it if you want to use Boost.StaticAssert
+* BOOST_CHRONO_USES_MPL_ASSERT: define it if you want to use Boost.MPL static asertions
+* BOOST_CHRONO_USES_ARRAY_ASSERT: define it if you want to use internal static asertions
+* nothing if you don't want static asertions
+
+When BOOST_CHRONO_USES_MPL_ASSERT is not defined the following symbols are defined as
+
+ #define BOOST_CHRONO_A_DURATION_REPRESENTATION_CAN_NOT_BE_A_DURATION \
+ "A duration representation can not be a duration"
+ #define BOOST_CHRONO_SECOND_TEMPLATE_PARAMETER_OF_DURATION_MUST_BE_A_STD_RATIO \
+ "Second template parameter of duration must be a std::ratio"
+ #define BOOST_CHRONO_DURATION_PERIOD_MUST_BE_POSITIVE \
+ "duration period must be positive"
+ #define BOOST_CHRONO_SECOND_TEMPLATE_PARAMETER_OF_TIME_POINT_MUST_BE_A_BOOST_CHRONO_DURATION \
+ "Second template parameter of time_point must be a boost::chrono::duration"
+
+Depending on the static assertion used system you will have an hint of the failing assertion either through the symbol or through the texte.
+
+[endsect]
+
[section:clock `Clock` Requirements]
-A clock represents a bundle consisting of a native `duration`, a native `time_point`, and a function `now()` to get the current `time_point`. A clock must meet the requirements in the following Table.
+A clock represents a bundle consisting of a native __duration__, a native __time_point__, and a function `now()` to get the current __time_point__. A clock must meet the requirements in the following Table.
In this table `C1` and `C2` denote `clock` types. `t1` and `t2` are values returned from `C1::now()` where the call returning `t1` happens before the call returning `t2` and both of these calls happen before `C1::time_point::max()`.
[table Clock Requirements
[[expression] [return type] [operational semantics]]
- [[`C1::rep`] [An arithmetic type or class emulating an arithmetic type. ] [The representation type of the native `duration` and `time_point`.]]
+ [[`C1::rep`] [An arithmetic type or class emulating an arithmetic type. ] [The representation type of the native __duration__ and __time_point__.]]
[[`C1::period`] [`ratio`] [The tick period of the clock in seconds.]]
- [[`C1::duration`] [`chrono::duration<C1::rep, C1::period>`] [The native `duration` type of the `clock`.]]
- [[`C1::time_point`] [`chrono::time_point<C1> or chrono::time_point<C2, C1::duration>`] [The native `time_point` type of the `clock`. Different clocks are permitted to share a `time_point` definition if it is valid to compare their time_points by comparing their respective `duration`s. `C1` and `C2` must refer to the same epoch.]]
+ [[`C1::duration`] [`chrono::duration<C1::rep, C1::period>`] [The native __duration__ type of the `clock`.]]
+ [[`C1::time_point`] [`chrono::time_point<C1> or chrono::time_point<C2, C1::duration>`] [The native __time_point__ type of the `clock`. Different clocks are permitted to share a __time_point__ definition if it is valid to compare their time_points by comparing their respective __duration__s. `C1` and `C2` must refer to the same epoch.]]
[[`C1::is_monotonic`] [`const bool`] [`true` if `t1 <= t2` is always `true`, else `false`. [*Note: A `clock` that can be adjusted backwards is not monotonic]]]
- [[`C1::now()`] [`C1::time_point`] [Returns a `time_point` representing the current point in time.]]
+ [[`C1::now()`] [`C1::time_point`] [Returns a __time_point__ representing the current point in time.]]
]
Models of Clock:
-* [@boost_chrono/reference/cpp0x.html#boost_chrono.reference.cpp0x.chrono_chrono_hpp.class__system_clock_ system_clock]
+* [@boost_chrono/reference/cpp0x.html#boost_chrono.reference.cpp0x.chrono_chrono_hpp.class__system_clock_ system_clock]
* [@boost_chrono/reference/cpp0x.html#boost_chrono.reference.cpp0x.chrono_chrono_hpp.class__monotonic_clock_ monotonic_clock]
* [@boost_chrono/reference/cpp0x.html#boost_chrono.reference.cpp0x.chrono_chrono_hpp.class__high_resolution_clock_ high_resolution_clock]
* [@boost_chrono/reference/other_clocks.html#boost_chrono.reference.other_clocks.process_cpu_clocks_hpp.class__process_real_cpu_clock_ process_real_cpu_clock]
@@ -2594,7 +2764,7 @@
template <class Rep> struct treat_as_floating_point
: boost::is_floating_point<Rep> {};
-The `duration` template uses the `treat_as_floating_point` trait to help determine if a `duration` with one tick period can be converted to another `duration` with a different tick period. If `treat_as_floating_point<Rep>::value` is `true`, then `Rep` is a floating point type and implicit conversions are allowed among `duration`s. Otherwise, the implicit convertibility depends on the tick periods of the `duration`s. If `Rep` is a class type which emulates a floating point type, the author of `Rep` can specialize `treat_as_floating_point` so that `duration` will treat this `Rep` as if it were a floating point type. Otherwise `Rep` is assumed to be an integral type, or a class emulating an integral type.
+The __duration__ template uses the `treat_as_floating_point` trait to help determine if a __duration__ with one tick period can be converted to another __duration__ with a different tick period. If `treat_as_floating_point<Rep>::value` is `true`, then `Rep` is a floating point type and implicit conversions are allowed among __duration__s. Otherwise, the implicit convertibility depends on the tick periods of the __duration__s. If `Rep` is a class type which emulates a floating point type, the author of `Rep` can specialize `treat_as_floating_point` so that __duration__ will treat this `Rep` as if it were a floating point type. Otherwise `Rep` is assumed to be an integral type, or a class emulating an integral type.
[endsect]
@@ -2609,7 +2779,7 @@
static BOOST_CHRONO_CONSTEXPR Rep min();
};
-The `duration` template uses the `duration_values` trait to construct special values of the `duration`s representation (`Rep`). This is done because the representation might be a class type with behavior which requires some other implementation to return these special values. In that case, the author of that class type should specialize `duration_values` to return the indicated values.
+The __duration__ template uses the `duration_values` trait to construct special values of the __duration__s representation (`Rep`). This is done because the representation might be a class type with behavior which requires some other implementation to return these special values. In that case, the author of that class type should specialize `duration_values` to return the indicated values.
[section:zero Static member Function `zero()`]
@@ -2641,7 +2811,7 @@
[endsect]
-[section `common_type` specializations]
+[section __common_type__ specializations]
template <class Rep1, class Period1, class Rep2, class Period2>
struct common_type<chrono::duration<Rep1, Period1>, chrono::duration<Rep2, Period2> >
@@ -2649,9 +2819,9 @@
typedef chrono::duration<typename common_type<Rep1, Rep2>::type, see below> type;
};
-The period of the `duration` indicated by this specialization of `common_type` is the greatest common divisor of `Period1` and `Period2`. This can be computed by forming a `ratio` of the greatest common divisor of `Period1::num` and `Period2::num`, and the least common multiple of `Period1::den` and `Period2::den`.
+The period of the __duration__ indicated by this specialization of __common_type__ is the greatest common divisor of `Period1` and `Period2`. This can be computed by forming a `ratio` of the greatest common divisor of `Period1::num` and `Period2::num`, and the least common multiple of `Period1::den` and `Period2::den`.
-[*Note:] The typedef type is the `duration` with the largest tick period possible where both `duration` arguments will convert to it without requiring a division operation. The representation of this type is intended to be able to hold any value resulting from this conversion, with the possible exception of round-off error when floating point `duration`s are involved (but not truncation error).
+[*Note:] The typedef type is the __duration__ with the largest tick period possible where both __duration__ arguments will convert to it without requiring a division operation. The representation of this type is intended to be able to hold any value resulting from this conversion, with the possible exception of round-off error when floating point __duration__s are involved (but not truncation error).
template <class Clock, class Duration1, class Duration2>
struct common_type<chrono::time_point<Clock, Duration1>, chrono::time_point<Clock, Duration2> >
@@ -2659,16 +2829,16 @@
typedef chrono::time_point<Clock, typename common_type<Duration1, Duration2>::type> type;
};
-The `common_type` of two `time_point`s is a `time_point` with the same `clock` (both have the same `clock`), and the `common_type` of the two `duration`s.
+The __common_type__ of two __time_point__s is a __time_point__ with the same `clock` (both have the same `clock`), and the __common_type__ of the two __duration__s.
[endsect]
[endsect]
-[section Class template `duration`]
+[section Class template __duration__]
-A `duration` measures time between two points in time (`time_point`). A `duration` has a representation which holds a count of ticks, and a tick period. The tick period is the amount of time which occurs from one tick to another in units of a second. It is expressed as a rational constant using `ratio`.
+A __duration__ measures time between two points in time (__time_point__). A __duration__ has a representation which holds a count of ticks, and a tick period. The tick period is the amount of time which occurs from one tick to another in units of a second. It is expressed as a rational constant using `ratio`.
namespace boost { namespace chrono {
@@ -2728,7 +2898,7 @@
}}
-Rep must be an arithmetic type, or a class emulating an arithmetic type, compile diagnostic otherwise. If `duration` is instantiated with the type of `Rep` being a `duration`, compile diagnostic is issued.
+Rep must be an arithmetic type, or a class emulating an arithmetic type, compile diagnostic otherwise. If __duration__ is instantiated with the type of `Rep` being a __duration__, compile diagnostic is issued.
Period must be an instantiation of `ratio`, compile diagnostic otherwise.
@@ -2742,7 +2912,7 @@
duration<double, ratio<1, 30> > holds a count using a double with a tick period of 1/30 second (a tick frequency of 30 Hz).
-The following members of `duration` do not throw an exception unless the indicated operations on the representations throw an exception.
+The following members of __duration__ do not throw an exception unless the indicated operations on the representations throw an exception.
[section:duration_c_1 Constructor `duration(const Rep2&)`]
@@ -2754,14 +2924,14 @@
* `treat_as_floating_point<rep>::value` is `true`, or
* `!treat_as_floating_point<rep>::value && !treat_as_floating_point<Rep2>::value` is `true`.
-If these constraints are not met, this constructor shall not participate in overload resolution. [*Note:] This requirement prevents construction of an integral-based `duration` with a floating point representation. Such a construction could easily lead to confusion about the value of the `duration`.
+If these constraints are not met, this constructor shall not participate in overload resolution. [*Note:] This requirement prevents construction of an integral-based __duration__ with a floating point representation. Such a construction could easily lead to confusion about the value of the __duration__.
[*Example:]
duration<int, milli> d(3.5); // do not compile
duration<int, milli> d(3); // ok
-[*Effects:] Constructs an object of type `duration`.
+[*Effects:] Constructs an object of type __duration__.
[*PostConditions:] `count() == static_cast<rep>(r)`.
@@ -2771,7 +2941,7 @@
template <class Rep2, class Period2>
BOOST_CHRONO_CONSTEXPR duration(const duration<Rep2, Period2>& d);
-[*Remarks:] `treat_as_floating_point<rep>::value`, or `ratio_divide<Period2, period>::type::den == 1`, else this constructor shall not participate in overload resolution. [*note] This requirement prevents implicit truncation error when converting between integral-based `duration`s. Such a construction could easily lead to confusion about the value of the `duration`.
+[*Remarks:] `treat_as_floating_point<rep>::value`, or `ratio_divide<Period2, period>::type::den == 1`, else this constructor shall not participate in overload resolution. [*note] This requirement prevents implicit truncation error when converting between integral-based __duration__s. Such a construction could easily lead to confusion about the value of the __duration__.
[*Example:]
@@ -2779,7 +2949,7 @@
duration<int, micro> us = ms; // ok
duration<int, milli> ms2 = us; // do not compile
-[*Effects:] Constructs an object of type `duration`, constructing `rep_` from `duration_cast<duration>(d).count()`.
+[*Effects:] Constructs an object of type __duration__, constructing `rep_` from `duration_cast<duration>(d).count()`.
[endsect]
[section:count Member function `count() const`]
@@ -2939,7 +3109,7 @@
duration<typename common_type<Rep1, Rep2>::type, Period>
operator*(const duration<Rep1, Period>& d, const Rep2& s);
-[*Requires:] Let `CR` represent the `common_type` of `Rep1` and `Rep2`. This function will not participate in overload resolution unless both `Rep1` and `Rep2` are implicitly convertible to `CR`.
+[*Requires:] Let `CR` represent the __common_type__ of `Rep1` and `Rep2`. This function will not participate in overload resolution unless both `Rep1` and `Rep2` are implicitly convertible to `CR`.
[*Returns:] `duration<CR, Period>(d) *= s`.
@@ -2950,7 +3120,7 @@
duration<typename common_type<Rep1, Rep2>::type, Period>
operator*(const Rep1& s, const duration<Rep2, Period>& d);
-[*Requires:] Let `CR` represent the `common_type` of `Rep1` and `Rep2`. This function will not participate in overload resolution unless both `Rep1` and `Rep2` are implicitly convertible to `CR`.
+[*Requires:] Let `CR` represent the __common_type__ of `Rep1` and `Rep2`. This function will not participate in overload resolution unless both `Rep1` and `Rep2` are implicitly convertible to `CR`.
[*Returns:] `d * s`.
@@ -2961,7 +3131,7 @@
duration<typename common_type<Rep1, Rep2>::type, Period>
operator/(const duration<Rep1, Period>& d, const Rep2& s);
-[*Requires:] Let `CR` represent the `common_type` of `Rep1` and `Rep2`. This function will not participate in overload resolution unless both `Rep1` and `Rep2` are implicitly convertible to `CR`, and `Rep2` is not an instantiation of `duration`.
+[*Requires:] Let `CR` represent the __common_type__ of `Rep1` and `Rep2`. This function will not participate in overload resolution unless both `Rep1` and `Rep2` are implicitly convertible to `CR`, and `Rep2` is not an instantiation of __duration__.
[*Returns:] `duration<CR, Period>(d) /= s`.
@@ -2972,7 +3142,7 @@
typename common_type<Rep1, Rep2>::type
operator/(const duration<Rep1, Period1>& lhs, const duration<Rep2, Period2>& rhs);
-[*Returns:] Let `CD` represent the `common_type` of the two `duration` arguments. Returns `CD(lhs).count() / CD(rhs).count()`.
+[*Returns:] Let `CD` represent the __common_type__ of the two __duration__ arguments. Returns `CD(lhs).count() / CD(rhs).count()`.
[endsect]
@@ -2981,7 +3151,7 @@
template <class Rep1, class Rep2, class Period>
double operator/(const Rep1& s, const duration<Rep2, Period>& d);
-[*Remarks:] Let `CR` represent the `common_type` of `Rep1` and `Rep2`. This function will not participate in overload resolution unless both `Rep1` and `Rep2` are implicitly convertible to `CR`, and `Rep1` is not an instantiation of `duration`.
+[*Remarks:] Let `CR` represent the __common_type__ of `Rep1` and `Rep2`. This function will not participate in overload resolution unless both `Rep1` and `Rep2` are implicitly convertible to `CR`, and `Rep1` is not an instantiation of __duration__.
[*Returns:] `CR(s)/duration<CR, Period>(d)`.
@@ -3019,7 +3189,7 @@
template <class Rep1, class Period1, class Rep2, class Period2>
bool operator==(const duration<Rep1, Period1>& lhs, const duration<Rep2, Period2>& rhs);
-[*Returns:] Let `CD` represent the `common_type` of the two `duration` arguments. Returns `CD(lhs).count() == CD(rhs).count()`
+[*Returns:] Let `CD` represent the __common_type__ of the two __duration__ arguments. Returns `CD(lhs).count() == CD(rhs).count()`
[endsect]
[section:duration_operator_neq_1 Non-Member function `operator!=(duration,duration)`]
@@ -3035,7 +3205,7 @@
template <class Rep1, class Period1, class Rep2, class Period2>
bool operator< (const duration<Rep1, Period1>& lhs, const duration<Rep2, Period2>& rhs);
-[*Returns:] Let `CD` represent the `common_type` of the two `duration` arguments. Returns `CD(lhs).count() < CD(rhs).count()`
+[*Returns:] Let `CD` represent the __common_type__ of the two __duration__ arguments. Returns `CD(lhs).count() < CD(rhs).count()`
[endsect]
[section:duration_operator_leq_1 Non-Member function `operator<=(duration,duration)`]
@@ -3068,9 +3238,9 @@
template <class ToDuration, class Rep, class Period>
ToDuration duration_cast(const duration<Rep, Period>& d);
-[*Requires:] This function will not participate in overload resolution unless `ToDuration` is an instantiation of `duration`.
+[*Requires:] This function will not participate in overload resolution unless `ToDuration` is an instantiation of __duration__.
-[*Returns:] Forms `CF` which is a `ratio` resulting from `ratio_divide<Period, typename ToDuration::period>::type`. Let `CR` be the `common_type` of `ToDuration::rep`, `Rep`, and `intmax_t`.
+[*Returns:] Forms `CF` which is a `ratio` resulting from `ratio_divide<Period, typename ToDuration::period>::type`. Let `CR` be the __common_type__ of `ToDuration::rep`, `Rep`, and `intmax_t`.
* If `CF::num == 1` and `CF::den == 1`, then returns `ToDuration(static_cast<typename ToDuration::rep>(d.count())) `
* else if `CF::num != 1` and `CF::den == 1`, then returns
@@ -3091,9 +3261,9 @@
-[section Class template `time_point`]
+[section Class template __time_point__]
-A `time_point` represents a point in time with respect to a specific clock.
+A __time_point__ represents a point in time with respect to a specific clock.
template <class Clock, class Duration>
class time_point {
@@ -3131,31 +3301,31 @@
static BOOST_CHRONO_CONSTEXPR time_point max();
};
-Clock must meet the [@boost_chrono/reference/cpp0x.html#boost_chrono.reference.cpp0x.chrono_chrono_hpp.class__system_clock_ Clock Requirements].
+Clock must meet the __clock_req__.
-Duration must be an instantiation of `duration`, compile diagnostic otherwise.
+Duration must be an instantiation of __duration__, compile diagnostic otherwise.
[section:time_point_c_1 Constructor `time_point()`]
time_point();
-[*Effects:] Constructs an object of `time_point`, initializing `d_` with `duration::zero()`. This `time_point` represents the epoch.
+[*Effects:] Constructs an object of __time_point__, initializing `d_` with `duration::zero()`. This __time_point__ represents the epoch.
[endsect]
[section:time_point_c_2 Constructor `time_point(const duration&)`]
time_point(const duration& d);
-[*Effects:] Constructs an object of `time_point`, initializing `d_` with `d`. This `time_point` represents the epoch `+ d`.
+[*Effects:] Constructs an object of __time_point__, initializing `d_` with `d`. This __time_point__ represents the epoch `+ d`.
[endsect]
[section:time_point_c_3 Constructor `time_point(const duration&)`]
template <class Duration2> time_point(const time_point<clock, Duration2>& t);
-[*Requires:] This function will not participate in overload resolution unless `Duration2` is implicitly convertible to `duration`.
+[*Requires:] This function will not participate in overload resolution unless `Duration2` is implicitly convertible to __duration__.
-[*Effects:] Constructs an object of `time_point`, initializing `d_` with `t.time_since_epoch()`.
+[*Effects:] Constructs an object of __time_point__, initializing `d_` with `t.time_since_epoch()`.
[endsect]
@@ -3296,7 +3466,7 @@
template <class ToDuration, class Clock, class Duration>
time_point<Clock, ToDuration> time_point_cast(const time_point<Clock, Duration>& t);
-[*Requires:] This function will not participate in overload resolution unless `ToDuration` is an instantiation of `duration`.
+[*Requires:] This function will not participate in overload resolution unless `ToDuration` is an instantiation of __duration__.
[*Returns:] `time_point<Clock, ToDuration>(duration_cast<ToDuration>(t.time_since_epoch()))`.
@@ -3323,7 +3493,7 @@
static time_point from_time_t(std::time_t t);
};
-`system_clock` satisfy the [@boost_chrono/reference/cpp0x.html#boost_chrono.reference.cpp0x.chrono_chrono_hpp.class__system_clock_ Clock Requirements]. In addition:
+`system_clock` satisfy the __clock_req__:
* `system_clock::duration::min() < system_clock::duration::zero()` is `true`.
@@ -3339,7 +3509,7 @@
time_point from_time_t(time_t t);
-[*Returns:] A `time_point` such that the `time_point` and `t` represent the same point in time, truncated to the courser of the precisions among `time_point` and `t`.
+[*Returns:] A __time_point__ such that the __time_point__ and `t` represent the same point in time, truncated to the courser of the precisions among __time_point__ and `t`.
[endsect]
[endsect]
@@ -3352,7 +3522,7 @@
[section Class `monotonic_clock`]
-`monotonic_clock` satisfy the [@boost_chrono/reference/cpp0x.html#boost_chrono.reference.cpp0x.chrono_chrono_hpp.class__system_clock_ Clock Requirements].
+`monotonic_clock` satisfy the __clock_req__.
`monotonic_clock` class provides access to the system-wide monotonic clock. The current time can be obtained by calling `monotonic_clock::now()`. There is no fixed relationship between values returned by `monotonic_clock::now()` and wall-clock time.
@@ -3376,7 +3546,7 @@
[section Class `high_resolution_clock`]
-`high_resolution_clock` satisfy the [@boost_chrono/reference/cpp0x.html#boost_chrono.reference.cpp0x.chrono_chrono_hpp.class__system_clock_ Clock Requirements].
+`high_resolution_clock` satisfy the __clock_req__.
#ifdef BOOST_CHRONO_HAS_CLOCK_MONOTONIC
typedef monotonic_clock high_resolution_clock; // as permitted by [time.clock.hires]
@@ -3416,7 +3586,7 @@
[section Class `process_real_cpu_clock`]
-`process_real_cpu_clock` satisfy the [@boost_chrono/reference/cpp0x.html#boost_chrono.reference.cpp0x.chrono_chrono_hpp.class__system_clock_ Clock Requirements].
+`process_real_cpu_clock` satisfy the __clock_req__.
`process_real_cpu_clock` class provides access to the real process wall-clock monotonic clock, i.e. the real CPU-time clock of the calling process. The process relative current time can be obtained by calling `process_real_cpu_clock::now()`.
@@ -3435,7 +3605,7 @@
[endsect]
[section Class `process_user_cpu_clock`]
-`process_user_cpu_clock` satisfy the [@boost_chrono/reference/cpp0x.html#boost_chrono.reference.cpp0x.chrono_chrono_hpp.class__system_clock_ Clock Requirements].
+`process_user_cpu_clock` satisfy the __clock_req__.
`process_user_cpu_clock` class provides access to the user CPU-time monotonic clock of the calling process. The process relative user current time can be obtained by calling `process_user_cpu_clock::now()`.
@@ -3455,7 +3625,7 @@
[section Class `process_system_cpu_clock`]
-`process_system_cpu_clock` satisfy the [@boost_chrono/reference/cpp0x.html#boost_chrono.reference.cpp0x.chrono_chrono_hpp.class__system_clock_ Clock Requirements].
+`process_system_cpu_clock` satisfy the __clock_req__.
`process_system_cpu_clock` class provides access to the system CPU-time monotonic clockof the calling process. The process relative system current time can be obtained by calling `process_system_cpu_clock::now()`.
@@ -3548,7 +3718,7 @@
[section:thread_clock_hpp Header `<boost/chrono/thread_clock.hpp>`]
[/==================================================================]
-Knowing the time a thread takes to execute is useful in both test and production environments.
+Knowing the time a thread takes to execute is useful in both test and production environments.
#define BOOST_CHRONO_HAS_THREAD_CLOCK
#define BOOST_CHRONO_THREAD_CLOCK_IS_MONOTONIC
@@ -3572,7 +3742,7 @@
[section Class `thread_clock`]
-`thread_clock` satisfy the [@boost_chrono/reference/cpp0x.html#boost_chrono.reference.cpp0x.chrono_chrono_hpp.class__system_clock_ Clock Requirements].
+`thread_clock` satisfy the __clock_req__.
`thread_clock` class provides access to the real thread wall-clock, i.e. the real CPU-time clock of the calling thread. The thread relative current time can be obtained by calling `thread_clock::now()`.
@@ -3606,7 +3776,7 @@
[[expression] [return type] [operational semantics]]
[[`C::suspend()`] [`void`] [Suspends the time counting of the clock C.]]
[[`C::resume()`] [`void`] [Resumes the time counting of the clock C.]]
- [[`C::suspended()`] [`duration`] [Returns the delay(duration during which the clock has been suspended.]]
+ [[`C::suspended()`] [__duration__] [Returns the delay(duration during which the clock has been suspended.]]
]
[section:SuspendibleClock_suspend Static Member Function `suspend()`]
@@ -3780,8 +3950,8 @@
[table Stopwatch Requirements
[[expression] [return type] [operational semantics]]
[[`S::clock`] [A model of the Clock concept.] [The clock associated to this Stopwatch.]]
- [[`S::duration`] [`S::clock::duration`] [The `duration` type of the `clock`.]]
- [[`S::time_point`] [`S::clock::time_point`] [The `time_point` type of the `clock`.]]
+ [[`S::duration`] [`S::clock::duration`] [The __duration__ type of the `clock`.]]
+ [[`S::time_point`] [`S::clock::time_point`] [The __time_point__ type of the `clock`.]]
[[`s.start()`] [`S::time_point`] [starts a Stopwatch.]]
[[`s.restart()`] [`std::pair<S::duration,S::time_point>`] [restarts a Stopwatch.]]
[[`s.stop()`] [`S::duration`] [stops a Stopwatch.]]
@@ -3885,7 +4055,7 @@
[section Template Class `stopwatch<>`]
-`stopwatch<>` is a model of a [@boost_chrono/reference/stopwatches.html#boost_chrono.reference.stopwatches.stopwatch_req `Stopwatch`].
+`stopwatch<>` is a model of a __stopwatch_concept__.
Knowing how long a part of a program takes to execute is useful in both test and production environments.
A `stopwatch` object measures elapsed time. It is recommended to use it with clocks that measure wall clock rather than CPU time since the intended use is performance measurement on systems where total elapsed time is more important than just process or CPU time.
@@ -3981,7 +4151,7 @@
[section Template Class `stopwatch_accumulator<>`]
-A `stopwatch_accumulator<>` is a model of a [@boost_chrono/reference/stopwatches.html#boost_chrono.reference.stopwatches.stopwatch_req `Stopwatch`] that allows to accumulate the time in several times instead of at once as it is the case of the class `stopwatch<>`.
+A `stopwatch_accumulator<>` is a model of a __stopwatch_concept__ that allows to accumulate the time in several times instead of at once as it is the case of the class `stopwatch<>`.
template <class Clock> class stopwatch_accumulator {
public:
@@ -5525,7 +5695,7 @@
* stopwatch_reporter is a convenient generic class reporting elapsed time for the Stopwatch concept.
* Added stopclock<Clock> shortcut stopwatch_reporter<stopwatch<Clcok>>
* Added scoped_stopclock which
-* Added typeof registration for classes `duration` and `time_point`
+* Added typeof registration for classes __duration__ and __time_point__
* The old classes process_times, process_clock, process_timer, timer and run_timer are deprecated as the preceding additions are more generic. However for backward compatibility they preserved until inclusion of the library in Boost. Next follows the equivalences:
* timer<> ~ stopwatch<>
@@ -5605,11 +5775,11 @@
[*Features:]
-* The C++0x Standard Library's `common_type`.
+* The C++0x Standard Library's __common_type__.
* The C++0x Standard Library's compile-time rational arithmetic.
* The C++0x Standard Library's time utilities, including:
- * Class template `duration`
- * Class template `time_point`
+ * Class template __duration__
+ * Class template __time_point__
* Clocks:
* `system_clock`
* `monotonic_clock`
@@ -5633,11 +5803,11 @@
See [http://www.open-std.org/jtc1/sc22/wg21/docs/papers/2008/n2661.htm [*N2661 - A Foundation to Sleep On]] which is very informative and provides motivation for key design decisions. The following sections are an extract from this document.
-[heading Is it possible for the user to pass a `duration` to a function with the units being ambiguous?]
+[heading Is it possible for the user to pass a __duration__ to a function with the units being ambiguous?]
No. No matter which option the author of `f` chooses above, the following client code will not compile:
- f(3); // Will not compile, 3 is not implicitly convertible to any `duration`
+ f(3); // Will not compile, 3 is not implicitly convertible to any __duration__
[heading Why duration needs operator%]
@@ -5743,6 +5913,31 @@
The library do not provides this feature.
+[heading What happens if I press Ctrl+C and program terminates? What log would Boost.chrono output?]
+
+[heading Can you explain the pros/cons of common_type against Boost.Typeof?]
+
+Even if in a first look they sound to be close, common_type and typeof have
+different purposes. You use typeof to get the type of an expression, while
+you use common_type to set explicitly the type returned of a template
+function. Both are complementary. For example with the preceding declaration
+and the needed Typeof registrations, you can do
+
+
+Suppose I have a mixed type vector2 class with a magnitude_squared function defined as:
+
+template <typename X, typename Y>
+BOOST_TYPEOF_TPL(X() * X() + Y() * Y()) magnitude_squared(const
+vector2<X, Y> &v) {
+ return v.x * v.x + v.y * v.y;
+}
+
+
+common_type is closer in nature to promote_args<class ...T> in boost/math/tools/promotion.hpp than it is to Boost.Typeof, though it is not exactly the same as promote_args either. common_type<T1, T2>::type simply represents the result of some operation on T1 and T2, and defaults to the type obtained by putting T1 and T2 into a conditional statement.
+
+It is meant to be customizable (via specialization) if this default is not appropriate.
+
+
[endsect]
[/====================================================]
@@ -5754,9 +5949,13 @@
Much thanks to Andrei Alexandrescu, Walter Brown, Peter Dimov, Jeff Garland, Terry Golubiewski, Daniel Krugler, Anthony Williams.
-Beman Dawes added the timer<>, process_clock, process_timer, run_timer classes which are now deprecated and replaced by the stopwatch, process_cpu_clock and stopclock classes.
+Beman Dawes added the `timer<>`, `process_clock`, `process_timer`, `run_timer` classes which are now deprecated and replaced by the `stopwatch`, `process_cpu_clock` and `stopclock` classes.
+
+Thanks to Adrew Chinoff for its multiple suggestion on `stopwatch_accumulator`, and helping me to polish the documentation.
+
+Thanks to Tom Tan for reporting some compiler issues with MSVC V10 beta and MinGW-gcc-4.4.0 and for the many suggestion he did concerning the new `stopwatch`, `process_cpu_clock`and `stopclock` classes and a deep help with wide characters implementation.
-Thanks to Tom Tan to report some compiler issues with MSVC V10 beta and MinGW-gcc-4.4.0 and for the many suggestion he did concerning the new stopwatch, process_cpu_clock, stopclock and function stopclock classes and a deep help with wide characters implementation.
+Thanks to Ronald Bock for reporting Valgind issues and for the many suggestion he did concerning the documentation.
[endsect]
@@ -5773,7 +5972,7 @@
bjam common_type
-[section `common_type`]
+[section __common_type__]
[table
[[Name] [kind] [Description] [Result] [Ticket]]
[[common_type_test] [run] [...] [Pass] [#]]
@@ -5865,38 +6064,47 @@
In the past I have chosen to use timeGetTime with timeBeginPeriod(1) for
high resolution timers to avoid these issues.
- ] [XXXX] [Open]]
- [[1] [operator/ was ambiguous] [Disambiguate duration operator/] [Close]]
- [[2] [CLOCK_MONOTONIC is not defined with cygwin/gcc 3.4] [Disable code when BOOST_CHRONO_HAS_CLOCK_MONOTONIC is not defined.] [Close]]
- [[3] [result of metafunctions ratio_multiply and ratio_divide were not normalized ratios] [Use of the nested ratio typedef type on ratio arithmetic operations.] [Close]]
- [[4] [Copy constructor from similar duration masked the defaulted operations] [Added duration defaulted implementations] [Close]]
- [[5] [INTMAX_C is not always defined] [Replace INTMAX_C by BOOST_INTMAX_C until boost/cstdint.hpp ensures INTMAX_C is always defined.] [Close]]
- [[6] [undefined BOOST_CHRONO_HAS_CLOCK_MONOTONIC when BOOST_CHRONO_WINDOWS_API] [Define BOOST_CHRONO_HAS_CLOCK_MONOTONIC when BOOST_CHRONO_WINDOWS_API] [Close]]
- [[7] [min/max macros intrussion] [Take care of Boost min/max recommendations] [Close]]
- [[8] [declaration of 'typedef class boost::chrono::duration<..> changes meaning of 'duration'] [complete qualification when defining nested typedef duration on clocks to avoid the following compile error:] [Close]]
- [[9] [VC++ warnings] [disable VC++ foolishness] [Close]]
- [[10] [conversion warning in test_duration] [removal of conversion warning in test_duration] [Close]]
- [[11] [MSVC reports a warning instead of an error when there is an integral constant overflow] [manage with MSVC reporting a warning instead of an error when there is an integral constant overflow] [Close]]
- [[12] [ambiguities with MSVC when using detail:: namespace] [Qualify with boost::detail boost::chrono::detail ] [Close]]
- [[13] [warning C4251: 'boost::chrono::run_timer::m_format' : class 'std::basic_string<_Elem,_Traits,_Ax>' needs to have dll-interface to be used by clients of class 'boost::chrono::run_timer'] [don't include inlines functions using the std::string m_format] [Close]]
- [[14] [Bad use of duration(0) on template classes] [remplace by duration::zero()] [Close]]
- [[15] [suspend doesn't works: partial_ not initialized] [initialize with duration::zero()] [Close]]
- [[16] [suspend doesn't works: elapsed doesn't take care of partial_] [take care of partial] [Close]]
- [[17] [suspend doesn't works: bad use of system::error_code & ec] [replace by system::error_code ec] [Close]]
- [[18] [warnings on mingw-gcc.4.4:[br]..\..\../boost/chrono/chrono.hpp: In copy constructor 'boost::chrono::time_point<boost::chrono::process_cpu_clock, boost::chrono::duration<boost::chrono::process_cpu_clock::times, boost::ratio<1ll, 1000000000ll> > >::time_point(const boost::chrono::time_point<boost::chrono::process_cpu_clock, boost::chrono::duration<boost::chrono::process_cpu_clock::times, boost::ratio<1ll, 1000000000ll> > >&)':
+ ] [???] [*Open*]]
+ [[1] [operator/ was ambiguous] [Disambiguate duration operator/] [Closed]]
+ [[2] [CLOCK_MONOTONIC is not defined with cygwin/gcc 3.4] [Disable code when BOOST_CHRONO_HAS_CLOCK_MONOTONIC is not defined.] [Closed]]
+ [[3] [result of metafunctions ratio_multiply and ratio_divide were not normalized ratios] [Use of the nested ratio typedef type on ratio arithmetic operations.] [Closed]]
+ [[4] [Copy constructor from similar duration masked the defaulted operations] [Added duration defaulted implementations] [Closed]]
+ [[5] [INTMAX_C is not always defined] [Replace INTMAX_C by BOOST_INTMAX_C until boost/cstdint.hpp ensures INTMAX_C is always defined.] [Closed]]
+ [[6] [undefined BOOST_CHRONO_HAS_CLOCK_MONOTONIC when BOOST_CHRONO_WINDOWS_API] [Define BOOST_CHRONO_HAS_CLOCK_MONOTONIC when BOOST_CHRONO_WINDOWS_API] [Closed]]
+ [[7] [min/max macros intrussion] [Take care of Boost min/max recommendations] [Closed]]
+ [[8] [declaration of 'typedef class boost::chrono::duration<..> changes meaning of 'duration'] [complete qualification when defining nested typedef duration on clocks to avoid the following compile error:] [Closed]]
+ [[9] [VC++ warnings] [disable VC++ foolishness] [Closed]]
+ [[10] [conversion warning in test_duration] [removal of conversion warning in test_duration] [Closed]]
+ [[11] [MSVC reports a warning instead of an error when there is an integral constant overflow] [manage with MSVC reporting a warning instead of an error when there is an integral constant overflow] [Closed]]
+ [[12] [ambiguities with MSVC when using detail:: namespace] [Qualify with boost::detail boost::chrono::detail ] [Closed]]
+ [[13] [warning C4251: 'boost::chrono::run_timer::m_format' : class 'std::basic_string<_Elem,_Traits,_Ax>' needs to have dll-interface to be used by clients of class 'boost::chrono::run_timer'] [don't include inlines functions using the std::string m_format] [Closed]]
+ [[14] [Bad use of duration(0) on template classes] [remplace by duration::zero()] [Closed]]
+ [[15] [suspend doesn't works: partial_ not initialized] [initialize with duration::zero()] [Closed]]
+ [[16] [suspend doesn't works: elapsed doesn't take care of partial_] [take care of partial] [Closed]]
+ [[17] [suspend doesn't works: bad use of system::error_code & ec] [replace by system::error_code ec] [Closed]]
+ [[18] [warnings on mingw-gcc.4.4:
+
+..\..\../boost/chrono/chrono.hpp: In copy constructor 'boost::chrono::time_point<boost::chrono::process_cpu_clock, boost::chrono::duration<boost::chrono::process_cpu_clock::times, boost::ratio<1ll, 1000000000ll> > >::time_point(const boost::chrono::time_point<boost::chrono::process_cpu_clock, boost::chrono::duration<boost::chrono::process_cpu_clock::times, boost::ratio<1ll, 1000000000ll> > >&)':
+..\..\../boost/chrono/chrono.hpp:816: warning: suggest parentheses around '&&' within '||'
..\..\../boost/chrono/chrono.hpp:816: warning: suggest parentheses around '&&' within '||'
-..\..\../boost/chrono/chrono.hpp:816: warning: suggest parentheses around '&&' within '||'] [???] [Open]]
- [[19] [Use of Specific formatters doesn't works] [XXXX] [Close]]
+
+] [???] [*Open*]]
+ [[19] [Use of Specific formatters doesn't works] [] [Closed]]
[[20] [boost/chrono/scoped_suspend.hpp(31) : warning C4520: 'boost::chrono::scoped_suspend<Clock>' : multiple default constructors specified
-] [XXXX] [Open]]
- [[[19] [suspendible_clock_test doesn't works in my mingw environement (issue with tss)] [XXXX] [Open]]
- [[#] [XXXX] [XXXX] [Close]]
+] [Remove the default constructor deletion ] [Closed]]
+ [[21] [suspendible_clock_test doesn't works in my mingw environement] [(issue with tss)] [*Open*]]
+ [[22] [error_code not initialized] [Use ec.clear() before throwing a exception.] [Closed]]
+ [[23] [boost/thread/detail/cv_status.hpp file was not commited] [commit file] [Closed]]
+ [[24] [Boost.Conversion was not packaged] [Package it] [Closed]]
+ [[25] [Valgrind issue: Conditional jump or move depends on uninitialised value(s)] [Replace the test] [Closed]]
+ [/[#] [XXXX] [XXXX] [Closed]]
]
+
[endsect]
[/=====================================]
Modified: sandbox/chrono/libs/chrono/doc/html/boost_chrono/appendices.html
==============================================================================
--- sandbox/chrono/libs/chrono/doc/html/boost_chrono/appendices.html (original)
+++ sandbox/chrono/libs/chrono/doc/html/boost_chrono/appendices.html 2010-06-26 11:18:46 EDT (Sat, 26 Jun 2010)
@@ -61,7 +61,7 @@
Acknowledgements</a></span></dt>
<dt><span class="section"> Appendix F: Tests</span></dt>
<dd><dl>
-<dt><span class="section">common_type
</span></dt>
+<dt><span class="section"> link_text</span></dt>
<dt><span class="section">ratio
</span></dt>
<dt><span class="section">chrono</span></dt>
<dt><span class="section">Other Clocks</span></dt>
Modified: sandbox/chrono/libs/chrono/doc/html/boost_chrono/appendices/acknowledgements.html
==============================================================================
--- sandbox/chrono/libs/chrono/doc/html/boost_chrono/appendices/acknowledgements.html (original)
+++ sandbox/chrono/libs/chrono/doc/html/boost_chrono/appendices/acknowledgements.html 2010-06-26 11:18:46 EDT (Sat, 26 Jun 2010)
@@ -42,15 +42,24 @@
Terry Golubiewski, Daniel Krugler, Anthony Williams.
</p>
<p>
- Beman Dawes added the timer<>, process_clock, process_timer, run_timer
- classes which are now deprecated and replaced by the stopwatch, process_cpu_clock
- and stopclock classes.
+ Beman Dawes added the <code class="computeroutput"><span class="identifier">timer</span><span class="special"><></span></code>, <code class="computeroutput"><span class="identifier">process_clock</span></code>,
+ <code class="computeroutput"><span class="identifier">process_timer</span></code>, <code class="computeroutput"><span class="identifier">run_timer</span></code> classes which are now deprecated
+ and replaced by the <code class="computeroutput"><span class="identifier">stopwatch</span></code>,
+ <code class="computeroutput"><span class="identifier">process_cpu_clock</span></code> and <code class="computeroutput"><span class="identifier">stopclock</span></code> classes.
</p>
<p>
- Thanks to Tom Tan to report some compiler issues with MSVC V10 beta and MinGW-gcc-4.4.0
- and for the many suggestion he did concerning the new stopwatch, process_cpu_clock,
- stopclock and function stopclock classes and a deep help with wide characters
- implementation.
+ Thanks to Adrew Chinoff for its multiple suggestion on <code class="computeroutput"><span class="identifier">stopwatch_accumulator</span></code>,
+ and helping me to polish the documentation.
+ </p>
+<p>
+ Thanks to Tom Tan for reporting some compiler issues with MSVC V10 beta and
+ MinGW-gcc-4.4.0 and for the many suggestion he did concerning the new <code class="computeroutput"><span class="identifier">stopwatch</span></code>, <code class="computeroutput"><span class="identifier">process_cpu_clock</span></code>and
+ <code class="computeroutput"><span class="identifier">stopclock</span></code> classes and a deep
+ help with wide characters implementation.
+ </p>
+<p>
+ Thanks to Ronald Bock for reporting Valgind issues and for the many suggestion
+ he did concerning the documentation.
</p>
</div>
<table xmlns:rev="http://www.cs.rpi.edu/~gregod/boost/tools/doc/revision" width="100%"><tr>
Modified: sandbox/chrono/libs/chrono/doc/html/boost_chrono/appendices/faq.html
==============================================================================
--- sandbox/chrono/libs/chrono/doc/html/boost_chrono/appendices/faq.html (original)
+++ sandbox/chrono/libs/chrono/doc/html/boost_chrono/appendices/faq.html 2010-06-26 11:18:46 EDT (Sat, 26 Jun 2010)
@@ -29,7 +29,7 @@
<a name="boost_chrono.appendices.faq"></a> Appendix D: FAQ
</h3></div></div></div>
<a name="boost_chrono.appendices.faq.how_important_is_the_order_of_the_common_type_lt__gt__template_arguments_"></a><h4>
-<a name="id4936054"></a>
+<a name="id4935741"></a>
<a href="faq.html#boost_chrono.appendices.faq.how_important_is_the_order_of_the_common_type_lt__gt__template_arguments_">How
important is the order of the common_type<> template arguments?</a>
</h4>
@@ -60,7 +60,7 @@
is also undefined.
</p>
<a name="boost_chrono.appendices.faq.why_does_stopwatch_reporter_only_display_millisecond_place_precision_when_the_underlying_clock_has_nanosecond_precision_"></a><h4>
-<a name="id4936464"></a>
+<a name="id4936151"></a>
<a href="faq.html#boost_chrono.appendices.faq.why_does_stopwatch_reporter_only_display_millisecond_place_precision_when_the_underlying_clock_has_nanosecond_precision_">Why
does stopwatch_reporter only display millisecond place precision when the
underlying Clock has nanosecond precision?</a>
@@ -71,7 +71,7 @@
dangerously.
</p>
<a name="boost_chrono.appendices.faq.why_does_stopwatch_reporter_sometimes_report_more_cpu_seconds_than_real_seconds_"></a><h4>
-<a name="id4936506"></a>
+<a name="id4936192"></a>
<a href="faq.html#boost_chrono.appendices.faq.why_does_stopwatch_reporter_sometimes_report_more_cpu_seconds_than_real_seconds_">Why
does stopwatch_reporter sometimes report more cpu seconds than real seconds?</a>
</h4>
@@ -81,13 +81,51 @@
be reporting at times.
</p>
<a name="boost_chrono.appendices.faq.can_i_obtain_statistics_of_the_time_elapsed_between_calls_to_a_function_"></a><h4>
-<a name="id4936539"></a>
+<a name="id4936225"></a>
<a href="faq.html#boost_chrono.appendices.faq.can_i_obtain_statistics_of_the_time_elapsed_between_calls_to_a_function_">Can
I obtain statistics of the time elapsed between calls to a function?</a>
</h4>
<p>
The library do not provides this feature.
</p>
+<a name="boost_chrono.appendices.faq.what_happens_if_i_press_ctrl_c_and_program_terminates__what_log_would_boost_chrono_output_"></a><h4>
+<a name="id4936252"></a>
+ <a href="faq.html#boost_chrono.appendices.faq.what_happens_if_i_press_ctrl_c_and_program_terminates__what_log_would_boost_chrono_output_">What
+ happens if I press Ctrl+C and program terminates? What log would Boost.chrono
+ output?</a>
+ </h4>
+<a name="boost_chrono.appendices.faq.can_you_explain_the_pros_cons_of_common_type_against_boost_typeof_"></a><h4>
+<a name="id4936283"></a>
+ <a href="faq.html#boost_chrono.appendices.faq.can_you_explain_the_pros_cons_of_common_type_against_boost_typeof_">Can
+ you explain the pros/cons of common_type against Boost.Typeof?</a>
+ </h4>
+<p>
+ Even if in a first look they sound to be close, common_type and typeof have
+ different purposes. You use typeof to get the type of an expression, while
+ you use common_type to set explicitly the type returned of a template function.
+ Both are complementary. For example with the preceding declaration and the
+ needed Typeof registrations, you can do
+ </p>
+<p>
+ Suppose I have a mixed type vector2 class with a magnitude_squared function
+ defined as:
+ </p>
+<p>
+ template <typename X, typename Y> BOOST_TYPEOF_TPL(X() * X() + Y()
+ * Y()) magnitude_squared(const vector2<X, Y> &v) { return v.x *
+ v.x + v.y * v.y; }
+ </p>
+<p>
+ common_type is closer in nature to promote_args<class ...T> in boost/math/tools/promotion.hpp
+ than it is to Boost.Typeof, though it is not exactly the same as promote_args
+ either. common_type<T1, T2>::type simply represents the result of some
+ operation on T1 and T2, and defaults to the type obtained by putting T1 and
+ T2 into a conditional statement.
+ </p>
+<p>
+ It is meant to be customizable (via specialization) if this default is not
+ appropriate.
+ </p>
</div>
<table xmlns:rev="http://www.cs.rpi.edu/~gregod/boost/tools/doc/revision" width="100%"><tr>
<td align="left"></td>
Modified: sandbox/chrono/libs/chrono/doc/html/boost_chrono/appendices/history.html
==============================================================================
--- sandbox/chrono/libs/chrono/doc/html/boost_chrono/appendices/history.html (original)
+++ sandbox/chrono/libs/chrono/doc/html/boost_chrono/appendices/history.html 2010-06-26 11:18:46 EDT (Sat, 26 Jun 2010)
@@ -317,8 +317,7 @@
Added scoped_stopclock which
</li>
<li>
- Added typeof registration for classes <code class="computeroutput"><span class="identifier">duration</span></code>
- and <code class="computeroutput"><span class="identifier">time_point</span></code>
+ Added typeof registration for classes link_text and <code class="computeroutput"><span class="identifier">time_point</span></code>
</li>
<li>
The old classes process_times, process_clock, process_timer, timer and
@@ -508,7 +507,7 @@
</p>
<div class="itemizedlist"><ul type="disc">
<li>
- The C++0x Standard Library's <code class="computeroutput"><span class="identifier">common_type</span></code>.
+ The C++0x Standard Library's link_text.
</li>
<li>
The C++0x Standard Library's compile-time rational arithmetic.
@@ -517,8 +516,8 @@
The C++0x Standard Library's time utilities, including:
<div class="itemizedlist"><ul type="circle">
<li>
- Class template <code class="computeroutput"><span class="identifier">duration</span></code>
-</li>
+ Class template link_text
+ </li>
<li>
Class template <code class="computeroutput"><span class="identifier">time_point</span></code>
</li>
Modified: sandbox/chrono/libs/chrono/doc/html/boost_chrono/appendices/perf.html
==============================================================================
--- sandbox/chrono/libs/chrono/doc/html/boost_chrono/appendices/perf.html (original)
+++ sandbox/chrono/libs/chrono/doc/html/boost_chrono/appendices/perf.html 2010-06-26 11:18:46 EDT (Sat, 26 Jun 2010)
@@ -69,7 +69,7 @@
with a variable lifetime.
</p>
<a name="boost_chrono.appendices.perf.single_threaded_recursive_function"></a><h4>
-<a name="id4939886"></a>
+<a name="id4939904"></a>
<a href="perf.html#boost_chrono.appendices.perf.single_threaded_recursive_function">Single-Threaded
Recursive function</a>
</h4>
@@ -92,7 +92,7 @@
and thread_clock.
</p>
<a name="boost_chrono.appendices.perf.multi_threaded_recursive_function"></a><h4>
-<a name="id4939935"></a>
+<a name="id4939953"></a>
<a href="perf.html#boost_chrono.appendices.perf.multi_threaded_recursive_function">Multi-Threaded
Recursive function</a>
</h4>
Modified: sandbox/chrono/libs/chrono/doc/html/boost_chrono/appendices/rationale.html
==============================================================================
--- sandbox/chrono/libs/chrono/doc/html/boost_chrono/appendices/rationale.html (original)
+++ sandbox/chrono/libs/chrono/doc/html/boost_chrono/appendices/rationale.html 2010-06-26 11:18:46 EDT (Sat, 26 Jun 2010)
@@ -32,20 +32,20 @@
and provides motivation for key design decisions. The following sections
are an extract from this document.
</p>
-<a name="boost_chrono.appendices.rationale.is_it_possible_for_the_user_to_pass_a__code__phrase_role__identifier__duration__phrase___code__to_a_function_with_the_units_being_ambiguous_"></a><h4>
-<a name="id4934837"></a>
- <a href="rationale.html#boost_chrono.appendices.rationale.is_it_possible_for_the_user_to_pass_a__code__phrase_role__identifier__duration__phrase___code__to_a_function_with_the_units_being_ambiguous_">Is
- it possible for the user to pass a <code class="computeroutput"><span class="identifier">duration</span></code>
- to a function with the units being ambiguous?</a>
+<a name="boost_chrono.appendices.rationale.is_it_possible_for_the_user_to_pass_a__link_text_to_a_function_with_the_units_being_ambiguous_"></a><h4>
+<a name="id4934536"></a>
+ <a href="rationale.html#boost_chrono.appendices.rationale.is_it_possible_for_the_user_to_pass_a__link_text_to_a_function_with_the_units_being_ambiguous_">Is
+ it possible for the user to pass a link_text to a function with the units
+ being ambiguous?</a>
</h4>
<p>
No. No matter which option the author of <code class="computeroutput"><span class="identifier">f</span></code>
chooses above, the following client code will not compile:
</p>
-<pre class="programlisting"><span class="identifier">f</span><span class="special">(</span><span class="number">3</span><span class="special">);</span> <span class="comment">// Will not compile, 3 is not implicitly convertible to any `duration`
+<pre class="programlisting"><span class="identifier">f</span><span class="special">(</span><span class="number">3</span><span class="special">);</span> <span class="comment">// Will not compile, 3 is not implicitly convertible to any __duration__
</span></pre>
<a name="boost_chrono.appendices.rationale.why_duration_needs_operator_"></a><h4>
-<a name="id4934927"></a>
+<a name="id4934614"></a>
<a href="rationale.html#boost_chrono.appendices.rationale.why_duration_needs_operator_">Why
duration needs operator%</a>
</h4>
@@ -73,7 +73,7 @@
<span class="special">};</span>
</pre>
<a name="boost_chrono.appendices.rationale.why_ratio_needs_copyconstruction_and_assignment_from_ratios_having_the_same_normalized_form"></a><h4>
-<a name="id4935507"></a>
+<a name="id4935194"></a>
<a href="rationale.html#boost_chrono.appendices.rationale.why_ratio_needs_copyconstruction_and_assignment_from_ratios_having_the_same_normalized_form">Why
ratio needs CopyConstruction and Assignment from ratios having the same normalized
form</a>
@@ -101,7 +101,7 @@
ratio<1,3> and the compilation succeeds.
</p>
<a name="boost_chrono.appendices.rationale.why_ratio_needs_the_nested_normalizer_typedef_type"></a><h4>
-<a name="id4935821"></a>
+<a name="id4935508"></a>
<a href="rationale.html#boost_chrono.appendices.rationale.why_ratio_needs_the_nested_normalizer_typedef_type">Why
ratio needs the nested normalizer typedef type</a>
</h4>
Modified: sandbox/chrono/libs/chrono/doc/html/boost_chrono/appendices/tests.html
==============================================================================
--- sandbox/chrono/libs/chrono/doc/html/boost_chrono/appendices/tests.html (original)
+++ sandbox/chrono/libs/chrono/doc/html/boost_chrono/appendices/tests.html 2010-06-26 11:18:46 EDT (Sat, 26 Jun 2010)
@@ -28,7 +28,7 @@
<a name="boost_chrono.appendices.tests"></a> Appendix F: Tests
</h3></div></div></div>
<div class="toc"><dl>
-<dt><span class="section">common_type
</span></dt>
+<dt><span class="section"> link_text</span></dt>
<dt><span class="section">ratio
</span></dt>
<dt><span class="section">chrono</span></dt>
<dt><span class="section">Other Clocks</span></dt>
@@ -47,7 +47,7 @@
</pre>
<div class="section" lang="en">
<div class="titlepage"><div><div><h4 class="title">
-<a name="boost_chrono.appendices.tests._common_type_"></a>common_type
+<a name="boost_chrono.appendices.tests.__common_type__"></a> link_text
</h4></div></div></div>
<div class="informaltable"><table class="table">
<colgroup>
Modified: sandbox/chrono/libs/chrono/doc/html/boost_chrono/appendices/tickets.html
==============================================================================
--- sandbox/chrono/libs/chrono/doc/html/boost_chrono/appendices/tickets.html (original)
+++ sandbox/chrono/libs/chrono/doc/html/boost_chrono/appendices/tickets.html 2010-06-26 11:18:46 EDT (Sat, 26 Jun 2010)
@@ -92,12 +92,12 @@
</td>
<td>
<p>
- XXXX
+ ???
</p>
</td>
<td>
<p>
- Open
+ <span class="bold"><strong>Open</strong></span>
</p>
</td>
</tr>
@@ -119,7 +119,7 @@
</td>
<td>
<p>
- Close
+ Closed
</p>
</td>
</tr>
@@ -141,7 +141,7 @@
</td>
<td>
<p>
- Close
+ Closed
</p>
</td>
</tr>
@@ -164,7 +164,7 @@
</td>
<td>
<p>
- Close
+ Closed
</p>
</td>
</tr>
@@ -186,7 +186,7 @@
</td>
<td>
<p>
- Close
+ Closed
</p>
</td>
</tr>
@@ -209,7 +209,7 @@
</td>
<td>
<p>
- Close
+ Closed
</p>
</td>
</tr>
@@ -231,7 +231,7 @@
</td>
<td>
<p>
- Close
+ Closed
</p>
</td>
</tr>
@@ -253,7 +253,7 @@
</td>
<td>
<p>
- Close
+ Closed
</p>
</td>
</tr>
@@ -277,7 +277,7 @@
</td>
<td>
<p>
- Close
+ Closed
</p>
</td>
</tr>
@@ -299,7 +299,7 @@
</td>
<td>
<p>
- Close
+ Closed
</p>
</td>
</tr>
@@ -321,7 +321,7 @@
</td>
<td>
<p>
- Close
+ Closed
</p>
</td>
</tr>
@@ -345,7 +345,7 @@
</td>
<td>
<p>
- Close
+ Closed
</p>
</td>
</tr>
@@ -367,7 +367,7 @@
</td>
<td>
<p>
- Close
+ Closed
</p>
</td>
</tr>
@@ -390,7 +390,7 @@
</td>
<td>
<p>
- Close
+ Closed
</p>
</td>
</tr>
@@ -412,7 +412,7 @@
</td>
<td>
<p>
- Close
+ Closed
</p>
</td>
</tr>
@@ -434,7 +434,7 @@
</td>
<td>
<p>
- Close
+ Closed
</p>
</td>
</tr>
@@ -456,7 +456,7 @@
</td>
<td>
<p>
- Close
+ Closed
</p>
</td>
</tr>
@@ -478,7 +478,7 @@
</td>
<td>
<p>
- Close
+ Closed
</p>
</td>
</tr>
@@ -490,8 +490,10 @@
</td>
<td>
<p>
- warnings on mingw-gcc.4.4:<br> ....../boost/chrono/chrono.hpp:
- In copy constructor 'boost::chrono::time_point<boost::chrono::process_cpu_clock,
+ warnings on mingw-gcc.4.4:
+ </p>
+ <p>
+ ....../boost/chrono/chrono.hpp: In copy constructor 'boost::chrono::time_point<boost::chrono::process_cpu_clock,
boost::chrono::duration<boost::chrono::process_cpu_clock::times,
boost::ratio<1ll, 1000000000ll> > >::time_point(const
boost::chrono::time_point<boost::chrono::process_cpu_clock,
@@ -500,6 +502,8 @@
warning: suggest parentheses around '&&' within '||' ....../boost/chrono/chrono.hpp:816:
warning: suggest parentheses around '&&' within '||'
</p>
+ <p>
+ </p>
</td>
<td>
<p>
@@ -508,7 +512,7 @@
</td>
<td>
<p>
- Open
+ <span class="bold"><strong>Open</strong></span>
</p>
</td>
</tr>
@@ -525,12 +529,11 @@
</td>
<td>
<p>
- XXXX
</p>
</td>
<td>
<p>
- Close
+ Closed
</p>
</td>
</tr>
@@ -548,57 +551,123 @@
</td>
<td>
<p>
- XXXX
+ Remove the default constructor deletion
+ </p>
+ </td>
+<td>
+ <p>
+ Closed
+ </p>
+ </td>
+</tr>
+<tr>
+<td>
+ <p>
+ 21
+ </p>
+ </td>
+<td>
+ <p>
+ suspendible_clock_test doesn't works in my mingw environement
+ </p>
+ </td>
+<td>
+ <p>
+ (issue with tss)
+ </p>
+ </td>
+<td>
+ <p>
+ <span class="bold"><strong>Open</strong></span>
+ </p>
+ </td>
+</tr>
+<tr>
+<td>
+ <p>
+ 22
+ </p>
+ </td>
+<td>
+ <p>
+ error_code not initialized
+ </p>
+ </td>
+<td>
+ <p>
+ Use ec.clear() before throwing a exception.
+ </p>
+ </td>
+<td>
+ <p>
+ Closed
+ </p>
+ </td>
+</tr>
+<tr>
+<td>
+ <p>
+ 23
+ </p>
+ </td>
+<td>
+ <p>
+ boost/thread/detail/cv_status.hpp file was not commited
+ </p>
+ </td>
+<td>
+ <p>
+ commit file
</p>
</td>
<td>
<p>
- Open
+ Closed
</p>
</td>
</tr>
<tr>
<td>
<p>
- [19
+ 24
</p>
</td>
<td>
<p>
- suspendible_clock_test doesn't works in my mingw environement (issue
- with tss)
+ Boost.Conversion was not packaged
</p>
</td>
<td>
<p>
- XXXX
+ Package it
</p>
</td>
<td>
<p>
- Open
+ Closed
</p>
</td>
</tr>
<tr>
<td>
<p>
- #
+ 25
</p>
</td>
<td>
<p>
- XXXX
+ Valgrind issue: Conditional jump or move depends on uninitialised
+ value(s)
</p>
</td>
<td>
<p>
- XXXX
+ Replace the test
</p>
</td>
<td>
<p>
- Close
+ Closed
</p>
</td>
</tr>
Modified: sandbox/chrono/libs/chrono/doc/html/boost_chrono/appendices/todo.html
==============================================================================
--- sandbox/chrono/libs/chrono/doc/html/boost_chrono/appendices/todo.html (original)
+++ sandbox/chrono/libs/chrono/doc/html/boost_chrono/appendices/todo.html 2010-06-26 11:18:46 EDT (Sat, 26 Jun 2010)
@@ -26,7 +26,7 @@
<a name="boost_chrono.appendices.todo"></a> Appendix I: Future plans
</h3></div></div></div>
<a name="boost_chrono.appendices.todo.tasks_to_do_before_review"></a><h4>
-<a name="id4940002"></a>
+<a name="id4940019"></a>
<a href="todo.html#boost_chrono.appendices.todo.tasks_to_do_before_review">Tasks
to do before review</a>
</h4>
@@ -42,7 +42,7 @@
</li>
</ul></div>
<a name="boost_chrono.appendices.todo.for_later_releases"></a><h4>
-<a name="id4940041"></a>
+<a name="id4940058"></a>
<a href="todo.html#boost_chrono.appendices.todo.for_later_releases">For later
releases</a>
</h4>
Modified: sandbox/chrono/libs/chrono/doc/html/boost_chrono/overview.html
==============================================================================
--- sandbox/chrono/libs/chrono/doc/html/boost_chrono/overview.html (original)
+++ sandbox/chrono/libs/chrono/doc/html/boost_chrono/overview.html 2010-06-26 11:18:46 EDT (Sat, 26 Jun 2010)
@@ -48,34 +48,36 @@
</p>
<div class="itemizedlist"><ul type="disc">
<li>
- One facility for representing time durations: <code class="computeroutput"><span class="identifier">duration</span></code>.
- Examples of time durations include seconds, minutes and nanoseconds. All
- of these units of time duration are united with a generic interface by the
- duration facility.
+ One facility for representing time durations: link_text. Examples of time
+ durations include <code class="computeroutput"><span class="identifier">seconds</span></code>,
+ <code class="computeroutput"><span class="identifier">minutes</span></code> and <code class="computeroutput"><span class="identifier">nanoseconds</span></code>. All of these units of time
+ duration are united with a generic interface by the link_text facility.
</li>
<li>
One facility for representing points in time: <code class="computeroutput"><span class="identifier">time_point</span></code>.
- A time_point represents an epoch plus or minus a duration. This paper leaves
- epochs unspecified. A time_point is associated with a clock.
+ A <code class="computeroutput"><span class="identifier">time_point</span></code> represents an
+ epoch plus or minus a link_text. The library leaves epochs unspecified. A
+ <code class="computeroutput"><span class="identifier">time_point</span></code> is associated
+ with a <span class="emphasis"><em>clock</em></span>.
</li>
<li>
Several clocks, some of which may not be available on any given platform:
<code class="computeroutput"><span class="identifier">system_clock</span></code>, <code class="computeroutput"><span class="identifier">monotonic_clock</span></code> and <code class="computeroutput"><span class="identifier">high_resolution_clock</span></code>.
A clock is a symbolic bundle of a native <code class="computeroutput"><span class="identifier">time_point</span></code>
- and <code class="computeroutput"><span class="identifier">duration</span></code>, and a function
- which returns a <code class="computeroutput"><span class="identifier">time_point</span></code>
+ and link_text, and a function which returns a <code class="computeroutput"><span class="identifier">time_point</span></code>
representing <span class="emphasis"><em>now</em></span>.
</li>
</ul></div>
<p>
Additionally, a minimal amount of general purpose infrastructure is provided
- which will support both the interface and implementation of the clocks, time_points
- and durations proposed herein. It is expected that these general purpose facilities
- will also find utility in far ranging user applications as well.
+ which will support both the interface and implementation of the <span class="emphasis"><em>clocks</em></span>,
+ __time<span class="underline">point</span>_s and <span class="underline">_duration</span>_s
+ proposed herein. It is expected that these general purpose facilities will
+ also find utility in far ranging user applications as well.
</p>
<div class="itemizedlist"><ul type="disc">
<li>
- common_type is a facility which is useful in specifying the type of the result
+ link_text is a facility which is useful in specifying the type of the result
of functions and operators which take a variety of types (e.g. "mixed
mode" complex arithmetic).
</li>
@@ -95,24 +97,24 @@
<div class="itemizedlist"><ul type="disc">
<li>
a Stopwatch middle layer: providing operations to start, stop, suspend or
- resume a <code class="computeroutput"><span class="identifier">Stopwatch</span></code> to measure
- the elapsed time.
+ resume a <span class="underline">_Stopwatch</span>_ to measure the
+ elapsed time.
<div class="itemizedlist"><ul type="circle">
<li>
-<code class="computeroutput"><span class="identifier">Stopwatch</span></code> concept
+<span class="underline">_Stopwatch</span>_ concept
</li>
<li>
Scoped helper classes allowing to pairwise start/stop operations, suspend/resume
- and resume/suspend a <code class="computeroutput"><span class="identifier">Stopwatch</span></code>.
+ and resume/suspend a <span class="underline">_Stopwatch</span>_.
</li>
<li>
<code class="computeroutput"><span class="identifier">stopwatch</span></code>, model of
- <code class="computeroutput"><span class="identifier">Stopwatch</span></code> capturing elapsed
- Clock times.
+ <span class="underline">_Stopwatch</span>_ capturing elapsed
+ <span class="underline">_Clock</span>_ times.
</li>
<li>
<code class="computeroutput"><span class="identifier">stopwatch_accumulator</span></code>,
- model of <code class="computeroutput"><span class="identifier">Stopwatch</span></code> capturing
+ model of <span class="underline">_Stopwatch</span>_ capturing
cummulated elapsed Clock times.
</li>
</ul></div>
@@ -123,7 +125,8 @@
<div class="itemizedlist"><ul type="circle">
<li>
<code class="computeroutput"><span class="identifier">stopwatch_reporter</span></code>, convenient
- reporting of models of Stopwatch results.
+ reporting of models of <span class="underline">_Stopwatch</span>_
+ results.
</li>
<li>
<code class="computeroutput"><span class="identifier">stopclock</span><span class="special"><</span><span class="identifier">Clock</span><span class="special">></span></code>
@@ -166,11 +169,11 @@
</p>
<p>
Last, <span class="bold"><strong>Boost.Chrono</strong></span> include typeof registration
- for classes <code class="computeroutput"><span class="identifier">duration</span></code> and <code class="computeroutput"><span class="identifier">time_point</span></code> so you can used auto emulated
- on C++03 compilers.
+ for classes link_text and <code class="computeroutput"><span class="identifier">time_point</span></code>
+ so you can used auto emulated on C++03 compilers.
</p>
<a name="boost_chrono.overview.how_to_use_this_documentation"></a><h3>
-<a name="id4803618"></a>
+<a name="id4803635"></a>
<a href="overview.html#boost_chrono.overview.how_to_use_this_documentation">How to
Use This Documentation</a>
</h3>
Modified: sandbox/chrono/libs/chrono/doc/html/boost_chrono/overview/motivation.html
==============================================================================
--- sandbox/chrono/libs/chrono/doc/html/boost_chrono/overview/motivation.html (original)
+++ sandbox/chrono/libs/chrono/doc/html/boost_chrono/overview/motivation.html 2010-06-26 11:18:46 EDT (Sat, 26 Jun 2010)
@@ -61,9 +61,9 @@
</p>
<p>
See N2661 - A Foundation to Sleep On which is
- very informative and provides motivation for key design decisions for <code class="computeroutput"><span class="identifier">common_type</span></code>, <code class="computeroutput"><span class="identifier">ratio</span></code>
- and <code class="computeroutput"><span class="identifier">chrono</span></code>. This documentation
- contains a lot of extracts from this document.
+ very informative and provides motivation for key design decisions for link_text,
+ <code class="computeroutput"><span class="identifier">ratio</span></code> and <code class="computeroutput"><span class="identifier">chrono</span></code>.
+ This documentation contains a lot of extracts from this document.
</p>
<div class="section" lang="en">
<div class="titlepage"><div><div><h4 class="title">
@@ -72,24 +72,23 @@
type</a>
</h4></div></div></div>
<p>
- <code class="computeroutput"><span class="identifier">common_type</span></code> has been a
- recurring theme in many places for many years. We've previously known it
- as promote and examples of it are spread throughout boost. It has been
- reinvented independently several times, because it is so useful.
+ link_text has been a recurring theme in many places for many years. We've
+ previously known it as promote and examples of it are spread throughout
+ boost. It has been reinvented independently several times, because it is
+ so useful.
</p>
<p>
Andrei Alexandrescu recently pointed us at a D library: std.traits - D
Programming Language - Digital Mars, which became the motivation for this
- particular name, and the variadic nature of this trait.
+ particular name, and the variadic nature of <a href="http://www.digitalmars.com/d/2.0/phobos/std_traits.html#CommonType" target="_top">this
+ trait</a>.
</p>
<p>
- In a nutshell, <code class="computeroutput"><span class="identifier">common_type</span></code>
- is a trait that takes 1 or more types, and returns a type which all of
- the types will convert to. The default definition demands this conversion
- be implicit. However the trait can be specialized for user-defined types
- which want to limit their inter-type conversions to explicit, and yet still
- want to interoperate with the <code class="computeroutput"><span class="identifier">common_type</span></code>
- facility.
+ In a nutshell, link_text is a trait that takes 1 or more types, and returns
+ a type which all of the types will convert to. The default definition demands
+ this conversion be implicit. However the trait can be specialized for user-defined
+ types which want to limit their inter-type conversions to explicit, and
+ yet still want to interoperate with the link_text facility.
</p>
<p>
<span class="bold"><strong>Example:</strong></span>
@@ -100,9 +99,11 @@
</pre>
<p>
In the above example, "mixed-mode" complex arithmetic is allowed.
- The return type is described by <code class="computeroutput"><span class="identifier">common_type</span></code>.
- For example the resulting type of adding a <code class="computeroutput"><span class="identifier">complex</span><span class="special"><</span><span class="keyword">int</span><span class="special">></span></code> and <code class="computeroutput"><span class="identifier">complex</span><span class="special"><</span><span class="keyword">double</span><span class="special">></span></code> might be a <code class="computeroutput"><span class="identifier">complex</span><span class="special"><</span><span class="keyword">double</span><span class="special">></span></code>. Another choice for the author might
- be:
+ The return type is described by link_text. For example the resulting type
+ of adding a <code class="computeroutput"><span class="identifier">complex</span><span class="special"><</span><span class="keyword">int</span><span class="special">></span></code>
+ and <code class="computeroutput"><span class="identifier">complex</span><span class="special"><</span><span class="keyword">double</span><span class="special">></span></code>
+ might be a <code class="computeroutput"><span class="identifier">complex</span><span class="special"><</span><span class="keyword">double</span><span class="special">></span></code>.
+ Another choice for the author might be:
</p>
<pre class="programlisting"><span class="keyword">template</span> <span class="special"><</span><span class="keyword">class</span> <span class="identifier">T</span><span class="special">,</span> <span class="keyword">class</span> <span class="identifier">U</span><span class="special">></span>
<span class="identifier">complex</span><span class="special"><</span><span class="keyword">typename</span> <span class="identifier">common_type</span><span class="special"><</span><span class="identifier">T</span><span class="special">,</span> <span class="identifier">U</span><span class="special">>::</span><span class="identifier">type</span><span class="special">></span>
@@ -116,8 +117,9 @@
<span class="identifier">min</span><span class="special">(</span><span class="identifier">T</span><span class="special">...</span> <span class="identifier">t</span><span class="special">);</span>
</pre>
<p>
- This is a very useful and broadly applicable utility. The <code class="computeroutput"><span class="identifier">duration</span></code> and <code class="computeroutput"><span class="identifier">time_point</span></code>
- facilities use it to make multi-precision arithmetic seamless and exact.
+ This is a very useful and broadly applicable utility. The link_text and
+ <code class="computeroutput"><span class="identifier">time_point</span></code> facilities use
+ it to make multi-precision arithmetic seamless and exact.
</p>
</div>
<div class="section" lang="en">
@@ -129,13 +131,13 @@
utility inspired by Walter Brown allowing one to easily and safely compute
rational values at compile time. The <code class="computeroutput"><span class="identifier">ratio</span></code>
class catches all errors (such as divide by zero and overflow) at compile
- time. It is used in the <code class="computeroutput"><span class="identifier">duration</span></code>
- and <code class="computeroutput"><span class="identifier">time_point</span></code> classes
- to efficiently create units of time. It can also be used in other "quantity"
- libraries (both std-defined and user-defined), or anywhere there is a rational
- constant which is known at compile time. The use of this utility can greatly
- reduce the chances of run time overflow because the <code class="computeroutput"><span class="identifier">ratio</span></code>
- (and any ratios resulting from <code class="computeroutput"><span class="identifier">ratio</span></code>
+ time. It is used in the link_text and <code class="computeroutput"><span class="identifier">time_point</span></code>
+ classes to efficiently create units of time. It can also be used in other
+ "quantity" libraries (both std-defined and user-defined), or
+ anywhere there is a rational constant which is known at compile time. The
+ use of this utility can greatly reduce the chances of run time overflow
+ because the <code class="computeroutput"><span class="identifier">ratio</span></code> (and
+ any ratios resulting from <code class="computeroutput"><span class="identifier">ratio</span></code>
arithmetic) are always reduced to lowest terms.
</p>
<p>
@@ -175,15 +177,14 @@
<a name="boost_chrono.overview.motivation.duration"></a>Duration
</h4></div></div></div>
<p>
- The <code class="computeroutput"><span class="identifier">duration</span></code> is the heart
- of this library. The interface that the user will see in everyday use is
- nearly identical to that of Boost.DateTime time <code class="computeroutput"><span class="identifier">duration</span></code>s
- authored by Jeff Garland, both in syntax and in behavior. This has been
- a very popular boost library for 7 years. There is an enormous positive
- history with this interface.
+ The link_text is the heart of this library. The interface that the user
+ will see in everyday use is nearly identical to that of Boost.DateTime
+ time <span class="underline">_duration</span>_s authored by Jeff
+ Garland, both in syntax and in behavior. This has been a very popular boost
+ library for 7 years. There is an enormous positive history with this interface.
</p>
<p>
- The library consists of six units of time <code class="computeroutput"><span class="identifier">duration</span></code>:
+ The library consists of six units of time link_text:
</p>
<div class="itemizedlist"><ul type="disc">
<li><code class="computeroutput"><span class="identifier">hours</span></code></li>
@@ -215,22 +216,22 @@
</p>
<p>
In Boost.DateTime, these units are united via inheritance. <span class="bold"><strong>Boost.Chrono</strong></span>
- instead unites these units through the class template <code class="computeroutput"><span class="identifier">duration</span></code>.
- That is, in <span class="bold"><strong>Boost.Chrono</strong></span> all six of the
- above units are nothing but typedefs to different instantiations of <code class="computeroutput"><span class="identifier">duration</span></code>. This change from Boost.DateTime
- has a far reaching positive impact, while not changing the syntax of the
- everyday use at all.
+ instead unites these units through the class template link_text. That is,
+ in <span class="bold"><strong>Boost.Chrono</strong></span> all six of the above units
+ are nothing but typedefs to different instantiations of link_text. This
+ change from Boost.DateTime has a far reaching positive impact, while not
+ changing the syntax of the everyday use at all.
</p>
<p>
The most immediate positive impact is that the library can immediately
generate any unit, any precision it needs. This is sometimes necessary
- when doing comparisons or arithmetic between <code class="computeroutput"><span class="identifier">duration</span></code>s
+ when doing comparisons or arithmetic between <span class="underline">_duration</span>_s
of differing precision, assuming one wants the comparison and arithmetic
to be exactly correct.
</p>
<p>
- A secondary benefit is that by publishing the class template <code class="computeroutput"><span class="identifier">duration</span></code> interface, user code can very
- easily create <code class="computeroutput"><span class="identifier">duration</span></code>s
+ A secondary benefit is that by publishing the class template link_text
+ interface, user code can very easily create <span class="underline">_duration</span>_s
with any precision they desire. The <code class="computeroutput"><span class="identifier">ratio</span></code>
utility is used to specify the precision, so as long as the precision can
be expressed by a rational constant with respect to seconds, this framework
@@ -252,39 +253,35 @@
</p>
<p>
<span class="bold"><strong>Boost.Chrono</strong></span> continues, and generalizes
- that philosophy. Not only can one specify the precision of a <code class="computeroutput"><span class="identifier">duration</span></code>, one can also specify its representation.
- This can be any integral type, or even a floating point type. Or it can
- be a user-defined type which emulates an arithmetic type. The six predefined
- units all use signed integral types as their representation. And they all
- have a minimum range of +/- 292 years. <code class="computeroutput"><span class="identifier">nanoseconds</span></code>
- needs 64 bits to cover that range. <code class="computeroutput"><span class="identifier">hours</span></code>
+ that philosophy. Not only can one specify the precision of a link_text,
+ one can also specify its representation. This can be any integral type,
+ or even a floating point type. Or it can be a user-defined type which emulates
+ an arithmetic type. The six predefined units all use signed integral types
+ as their representation. And they all have a minimum range of +/- 292 years.
+ <code class="computeroutput"><span class="identifier">nanoseconds</span></code> needs 64 bits
+ to cover that range. <code class="computeroutput"><span class="identifier">hours</span></code>
needs only 23 bits to cover that range.
</p>
-<a name="boost_chrono.overview.motivation.duration.so_what_exactly_is_a__code__phrase_role__identifier__duration__phrase___code__and_how_do_i_use_one_"></a><h5>
-<a name="id4759703"></a>
- <a href="motivation.html#boost_chrono.overview.motivation.duration.so_what_exactly_is_a__code__phrase_role__identifier__duration__phrase___code__and_how_do_i_use_one_">So
- What Exactly is a <code class="computeroutput"><span class="identifier">duration</span></code>
- and How Do I Use One?</a>
+<a name="boost_chrono.overview.motivation.duration.so_what_exactly_is_a__link_text_and_how_do_i_use_one_"></a><h5>
+<a name="id4759588"></a>
+ <a href="motivation.html#boost_chrono.overview.motivation.duration.so_what_exactly_is_a__link_text_and_how_do_i_use_one_">So
+ What Exactly is a link_text and How Do I Use One?</a>
</h5>
<p>
- A <code class="computeroutput"><span class="identifier">duration</span></code> has a representation
- and a tick period (precision).
+ A link_text has a representation and a tick period (precision).
</p>
<pre class="programlisting"><span class="keyword">template</span> <span class="special"><</span><span class="keyword">class</span> <span class="identifier">Rep</span><span class="special">,</span> <span class="keyword">class</span> <span class="identifier">Period</span> <span class="special">=</span> <span class="identifier">ratio</span><span class="special"><</span><span class="number">1</span><span class="special">></span> <span class="special">></span> <span class="keyword">class</span> <span class="identifier">duration</span><span class="special">;</span>
</pre>
<p>
The representation is simply any arithmetic type, or an emulation of such
a type. The representation stores a count of ticks. This count is the only
- data member stored in a <code class="computeroutput"><span class="identifier">duration</span></code>.
- If the representation is floating point, it can store fractions of a tick
- to the precision of the representation. The tick period is represented
- by a <code class="computeroutput"><span class="identifier">ratio</span></code> and is encoded
- into the <code class="computeroutput"><span class="identifier">duration</span></code>'s type,
- instead of stored. The tick period only has an impact on the behavior of
- the <code class="computeroutput"><span class="identifier">duration</span></code> when a conversion
- between different <code class="computeroutput"><span class="identifier">duration</span></code>'s
- is attempted. The tick period is completely ignored when simply doing arithmetic
- among like <code class="computeroutput"><span class="identifier">duration</span></code>s.
+ data member stored in a link_text. If the representation is floating point,
+ it can store fractions of a tick to the precision of the representation.
+ The tick period is represented by a <code class="computeroutput"><span class="identifier">ratio</span></code>
+ and is encoded into the link_text's type, instead of stored. The tick period
+ only has an impact on the behavior of the link_text when a conversion between
+ different link_text's is attempted. The tick period is completely ignored
+ when simply doing arithmetic among like <span class="underline">_duration</span>_s.
</p>
<p>
<span class="bold"><strong>Example:</strong></span>
@@ -306,21 +303,21 @@
to microseconds, resulting in a relatively large number of microseconds.
</p>
<p>
- If you need to access the tick count within a <code class="computeroutput"><span class="identifier">duration</span></code>,
- there is a member <code class="computeroutput"><span class="identifier">count</span><span class="special">()</span></code> which simply returns the stored tick
- count.
+ If you need to access the tick count within a link_text, there is a member
+ <code class="computeroutput"><span class="identifier">count</span><span class="special">()</span></code>
+ which simply returns the stored tick count.
</p>
<pre class="programlisting"><span class="keyword">long</span> <span class="keyword">long</span> <span class="identifier">tc</span> <span class="special">=</span> <span class="identifier">us4</span><span class="special">.</span><span class="identifier">count</span><span class="special">();</span> <span class="comment">// tc is 300000005
</span></pre>
<p>
- These <code class="computeroutput"><span class="identifier">duration</span></code>s have very
- simple, very predictable, and very observable behavior. After all, this
- is really nothing but the time tested interface of Jeff's boost time <code class="computeroutput"><span class="identifier">duration</span></code> library (unified with templates
- instead of inheritance).
- </p>
-<a name="boost_chrono.overview.motivation.duration.what_happens_if_i_assign__code__phrase_role__identifier__m3__phrase___phrase_role__special_____phrase___phrase_role__identifier__us3__phrase___code__to__code__phrase_role__identifier__minutes__phrase___code__instead_of__code__phrase_role__identifier__microseconds__phrase___code__"></a><h5>
-<a name="id4813430"></a>
- <a href="motivation.html#boost_chrono.overview.motivation.duration.what_happens_if_i_assign__code__phrase_role__identifier__m3__phrase___phrase_role__special_____phrase___phrase_role__identifier__us3__phrase___code__to__code__phrase_role__identifier__minutes__phrase___code__instead_of__code__phrase_role__identifier__microseconds__phrase___code__">What
+ These <span class="underline">_duration</span>_s have very simple,
+ very predictable, and very observable behavior. After all, this is really
+ nothing but the time tested interface of Jeff's boost time link_text library
+ (unified with templates instead of inheritance).
+ </p>
+<a name="boost_chrono.overview.motivation.duration.what_happens_if_i_assign__code__phrase_role__identifier__m3__phrase___phrase_role__special_____phrase___phrase_role__identifier__us3__phrase___code__to___code__phrase_role__identifier__minutes__phrase___code__instead_of__code__phrase_role__identifier__microseconds__phrase___code__"></a><h5>
+<a name="id4813238"></a>
+ <a href="motivation.html#boost_chrono.overview.motivation.duration.what_happens_if_i_assign__code__phrase_role__identifier__m3__phrase___phrase_role__special_____phrase___phrase_role__identifier__us3__phrase___code__to___code__phrase_role__identifier__minutes__phrase___code__instead_of__code__phrase_role__identifier__microseconds__phrase___code__">What
happens if I assign <code class="computeroutput"><span class="identifier">m3</span> <span class="special">+</span> <span class="identifier">us3</span></code>
to <code class="computeroutput"><span class="identifier">minutes</span></code> instead of
<code class="computeroutput"><span class="identifier">microseconds</span></code>?</a>
@@ -336,7 +333,7 @@
ignored. This is similar to the problem of assigning a double to an <code class="computeroutput"><span class="keyword">int</span></code>: the fractional part gets silently discarded.
</p>
<a name="boost_chrono.overview.motivation.duration.but_what_if_the_truncation_behavior_is_what_i_want_to_do_"></a><h5>
-<a name="id4813599"></a>
+<a name="id4813406"></a>
<a href="motivation.html#boost_chrono.overview.motivation.duration.but_what_if_the_truncation_behavior_is_what_i_want_to_do_">But
what if the truncation behavior is what I want to do?</a>
</h5>
@@ -347,18 +344,17 @@
<pre class="programlisting"><span class="identifier">minutes</span> <span class="identifier">m4</span> <span class="special">=</span> <span class="identifier">duration_cast</span><span class="special"><</span><span class="identifier">minutes</span><span class="special">>(</span><span class="identifier">m3</span> <span class="special">+</span> <span class="identifier">us3</span><span class="special">);</span> <span class="comment">// m4.count() == 5
</span></pre>
<p>
- In general, one can perform <code class="computeroutput"><span class="identifier">duration</span></code>
- arithmetic at will. If <code class="computeroutput"><span class="identifier">duration_cast</span></code>
- isn't used, and it compiles, the arithmetic is exact. Any place one wants
- to override this exact arithmetic behavior, duration_cast can be used to
- explicitly specify that desire. The <code class="computeroutput"><span class="identifier">duration_cast</span></code>
- has the same efficiency as the implicit conversion, and will even be exact
- as often as it can.
- </p>
-<a name="boost_chrono.overview.motivation.duration.i_m_trafficking_in_floating_point__code__phrase_role__identifier__duration__phrase___code_s__i_don_t_want_to_deal_with_writing__code__phrase_role__identifier__duration_cast__phrase___code__all_over_the_place__i_m_content_with_the_precision_of_my_floating_point_representation"></a><h5>
-<a name="id4813736"></a>
- <a href="motivation.html#boost_chrono.overview.motivation.duration.i_m_trafficking_in_floating_point__code__phrase_role__identifier__duration__phrase___code_s__i_don_t_want_to_deal_with_writing__code__phrase_role__identifier__duration_cast__phrase___code__all_over_the_place__i_m_content_with_the_precision_of_my_floating_point_representation">I'm
- trafficking in floating point <code class="computeroutput"><span class="identifier">duration</span></code>s.
+ In general, one can perform link_text arithmetic at will. If <code class="computeroutput"><span class="identifier">duration_cast</span></code> isn't used, and it compiles,
+ the arithmetic is exact. Any place one wants to override this exact arithmetic
+ behavior, duration_cast can be used to explicitly specify that desire.
+ The <code class="computeroutput"><span class="identifier">duration_cast</span></code> has the
+ same efficiency as the implicit conversion, and will even be exact as often
+ as it can.
+ </p>
+<a name="boost_chrono.overview.motivation.duration.i_m_trafficking_in_floating_point__emphasis_role__underline___duration__emphasis__s__i_don_t_want_to_deal_with_writing__code__phrase_role__identifier__duration_cast__phrase___code__all_over_the_place__i_m_content_with_the_precision_of_my_floating_point_representation"></a><h5>
+<a name="id4813533"></a>
+ <a href="motivation.html#boost_chrono.overview.motivation.duration.i_m_trafficking_in_floating_point__emphasis_role__underline___duration__emphasis__s__i_don_t_want_to_deal_with_writing__code__phrase_role__identifier__duration_cast__phrase___code__all_over_the_place__i_m_content_with_the_precision_of_my_floating_point_representation">I'm
+ trafficking in floating point <span class="underline">_duration</span>_s.
I don't want to deal with writing <code class="computeroutput"><span class="identifier">duration_cast</span></code>
all over the place. I'm content with the precision of my floating point
representation</a>
@@ -371,7 +367,7 @@
<span class="identifier">dminutes</span> <span class="identifier">dm4</span> <span class="special">=</span> <span class="identifier">m3</span> <span class="special">+</span> <span class="identifier">us3</span><span class="special">;</span> <span class="comment">// dm4.count() == 5.000000083333333
</span></pre>
<a name="boost_chrono.overview.motivation.duration.how_expensive_is_all_of_this_"></a><h5>
-<a name="id4813898"></a>
+<a name="id4813691"></a>
<a href="motivation.html#boost_chrono.overview.motivation.duration.how_expensive_is_all_of_this_">How
expensive is all of this?</a>
</h5>
@@ -384,20 +380,18 @@
and being subsequently ignored in converting the run time values of the
tick counts.
</p>
-<a name="boost_chrono.overview.motivation.duration.how_complicated_is_it_to_build_a_function_taking_a__code__phrase_role__identifier__duration__phrase___code__parameter_"></a><h5>
-<a name="id4813948"></a>
- <a href="motivation.html#boost_chrono.overview.motivation.duration.how_complicated_is_it_to_build_a_function_taking_a__code__phrase_role__identifier__duration__phrase___code__parameter_">How
- complicated is it to build a function taking a <code class="computeroutput"><span class="identifier">duration</span></code>
- parameter?</a>
+<a name="boost_chrono.overview.motivation.duration.how_complicated_is_it_to_build_a_function_taking_a__link_text_parameter_"></a><h5>
+<a name="id4813743"></a>
+ <a href="motivation.html#boost_chrono.overview.motivation.duration.how_complicated_is_it_to_build_a_function_taking_a__link_text_parameter_">How
+ complicated is it to build a function taking a link_text parameter?</a>
</h5>
<p>
There are several options open to the user:
</p>
<div class="itemizedlist"><ul type="disc"><li>
- If the author of the function wants to accept any <code class="computeroutput"><span class="identifier">duration</span></code>,
- and is willing to work in floating point <code class="computeroutput"><span class="identifier">duration</span></code>s,
- he can simply use any floating point <code class="computeroutput"><span class="identifier">duration</span></code>
- as the parameter:
+ If the author of the function wants to accept any link_text, and is willing
+ to work in floating point <span class="underline">_duration</span>_s,
+ he can simply use any floating point link_text as the parameter:
</li></ul></div>
<pre class="programlisting"><span class="keyword">void</span> <span class="identifier">f</span><span class="special">(</span><span class="identifier">duration</span><span class="special"><</span><span class="keyword">double</span><span class="special">></span> <span class="identifier">d</span><span class="special">)</span> <span class="comment">// accept floating point seconds
</span><span class="special">{</span>
@@ -407,7 +401,7 @@
<span class="identifier">f</span><span class="special">(</span><span class="identifier">microseconds</span><span class="special">(</span><span class="number">3</span><span class="special">));</span>
</pre>
<div class="itemizedlist"><ul type="disc"><li>
- If the author of the function wants to traffic only in integral <code class="computeroutput"><span class="identifier">duration</span></code>s, and is content with handling
+ If the author of the function wants to traffic only in integral <span class="underline">_duration</span>_s, and is content with handling
nothing finer than say nanoseconds (just as an example), he can simply
specify nanoseconds as the parameter:
</li></ul></div>
@@ -419,25 +413,25 @@
<span class="identifier">f</span><span class="special">(</span><span class="identifier">microseconds</span><span class="special">(</span><span class="number">3</span><span class="special">));</span>
</pre>
<p>
- In this design, if the client wants to pass in a floating point <code class="computeroutput"><span class="identifier">duration</span></code>, or a <code class="computeroutput"><span class="identifier">duration</span></code>
- of finer precision than nanoseconds, then the client is responsible for
- choosing his own rounding mode in the conversion to nanoseconds.
+ In this design, if the client wants to pass in a floating point link_text,
+ or a link_text of finer precision than nanoseconds, then the client is
+ responsible for choosing his own rounding mode in the conversion to nanoseconds.
</p>
<pre class="programlisting"><span class="identifier">duration</span><span class="special"><</span><span class="keyword">double</span><span class="special">></span> <span class="identifier">s</span><span class="special">(</span><span class="number">1.</span><span class="special">/</span><span class="number">3</span><span class="special">);</span> <span class="comment">// 1/3 of a second
</span><span class="identifier">f</span><span class="special">(</span><span class="identifier">duration_cast</span><span class="special"><</span><span class="identifier">nanoseconds</span><span class="special">>(</span><span class="identifier">s</span><span class="special">));</span> <span class="comment">// round towards zero in conversion to nanoseconds
</span></pre>
<p>
In the example above, the client of f has chosen "round towards zero"
- as the desired rounding mode to nanoseconds. If the client has a <code class="computeroutput"><span class="identifier">duration</span></code> that won't exactly convert to
- nanoseconds, and fails to choose how the conversion will take place, the
- compiler will refuse the call:
+ as the desired rounding mode to nanoseconds. If the client has a link_text
+ that won't exactly convert to nanoseconds, and fails to choose how the
+ conversion will take place, the compiler will refuse the call:
</p>
<pre class="programlisting"><span class="identifier">f</span><span class="special">(</span><span class="identifier">s</span><span class="special">);</span> <span class="comment">// does not compile
</span></pre>
<div class="itemizedlist"><ul type="disc"><li>
- If the author of the function wants to accept any <code class="computeroutput"><span class="identifier">duration</span></code>,
- but wants to work with integral representations and wants to control
- the rounding mode internally, then he can template the function:
+ If the author of the function wants to accept any link_text, but wants
+ to work with integral representations and wants to control the rounding
+ mode internally, then he can template the function:
</li></ul></div>
<pre class="programlisting"><span class="keyword">template</span> <span class="special"><</span><span class="keyword">class</span> <span class="identifier">Rep</span><span class="special">,</span> <span class="keyword">class</span> <span class="identifier">Period</span><span class="special">></span>
<span class="keyword">void</span> <span class="identifier">f</span><span class="special">(</span><span class="identifier">duration</span><span class="special"><</span><span class="identifier">Rep</span><span class="special">,</span> <span class="identifier">Period</span><span class="special">></span> <span class="identifier">d</span><span class="special">)</span>
@@ -453,8 +447,8 @@
</pre>
<div class="itemizedlist"><ul type="disc"><li>
If the author in the example does not want to accept floating point based
- <code class="computeroutput"><span class="identifier">duration</span></code>s, he can enforce
- that behavior like so:
+ <span class="underline">_duration</span>_s, he can enforce that
+ behavior like so:
</li></ul></div>
<pre class="programlisting"><span class="keyword">template</span> <span class="special"><</span><span class="keyword">class</span> <span class="identifier">Period</span><span class="special">></span>
<span class="keyword">void</span> <span class="identifier">f</span><span class="special">(</span><span class="identifier">duration</span><span class="special"><</span><span class="keyword">long</span> <span class="keyword">long</span><span class="special">,</span> <span class="identifier">Period</span><span class="special">></span> <span class="identifier">d</span><span class="special">)</span>
@@ -469,15 +463,14 @@
<span class="identifier">f</span><span class="special">(</span><span class="identifier">duration</span><span class="special"><</span><span class="keyword">long</span> <span class="keyword">long</span><span class="special">,</span> <span class="identifier">pico</span><span class="special">>(</span><span class="number">333333333333</span><span class="special">));</span> <span class="comment">// About 1/3 of a second worth of picoseconds
</span></pre>
<p>
- Clients with floating point <code class="computeroutput"><span class="identifier">duration</span></code>s
- who want to use f will now have to convert to an integral <code class="computeroutput"><span class="identifier">duration</span></code> themselves before passing the
- result to f.
+ Clients with floating point <span class="underline">_duration</span>_s
+ who want to use f will now have to convert to an integral link_text themselves
+ before passing the result to f.
</p>
<p>
In summary, the author of f has quite a bit of flexibility and control
in the interface he wants to provide his clients with, and easy options
- for manipulating that <code class="computeroutput"><span class="identifier">duration</span></code>
- internal to his function.
+ for manipulating that link_text internal to his function.
</p>
</div>
<div class="section" lang="en">
@@ -485,18 +478,19 @@
<a name="boost_chrono.overview.motivation.clocks"></a>Clocks
</h4></div></div></div>
<p>
- While <code class="computeroutput"><span class="identifier">duration</span></code>s only have
- precision and representation to concern themselves, clocks and <code class="computeroutput"><span class="identifier">time_point</span></code>s are intimately related and
- refer to one another. Because clocks are simpler to explain, we will do
- so first without fully explaining <code class="computeroutput"><span class="identifier">time_point</span></code>s.
- Once clocks are introduced, it will be easier to then fill in what a <code class="computeroutput"><span class="identifier">time_point</span></code> is.
+ While <span class="underline">_duration</span>_s only have precision
+ and representation to concern themselves, clocks and __time<span class="underline">point</span>_s
+ are intimately related and refer to one another. Because clocks are simpler
+ to explain, we will do so first without fully explaining __time<span class="underline">point</span>_s. Once clocks are introduced, it will
+ be easier to then fill in what a <code class="computeroutput"><span class="identifier">time_point</span></code>
+ is.
</p>
<p>
A clock is a concept which bundles 3 things:
</p>
<div class="orderedlist"><ol type="1">
<li>
- A concrete <code class="computeroutput"><span class="identifier">duration</span></code> type.
+ A concrete link_text type.
</li>
<li>
A concrete <code class="computeroutput"><span class="identifier">time_point</span></code>
@@ -545,8 +539,7 @@
<pre class="programlisting"><span class="identifier">Clock</span><span class="special">::</span><span class="identifier">time_point</span> <span class="identifier">t1</span> <span class="special">=</span> <span class="identifier">Clock</span><span class="special">::</span><span class="identifier">now</span><span class="special">();</span>
</pre>
<p>
- And one can get the time <code class="computeroutput"><span class="identifier">duration</span></code>
- between two <code class="computeroutput"><span class="identifier">time_point</span></code>s
+ And one can get the time link_text between two __time<span class="underline">point</span>_s
associated with Clock with:
</p>
<pre class="programlisting"><span class="identifier">Clock</span><span class="special">::</span><span class="identifier">duration</span> <span class="identifier">d</span> <span class="special">=</span> <span class="identifier">t1</span> <span class="special">-</span> <span class="identifier">Clock</span><span class="special">::</span><span class="identifier">now</span><span class="special">();</span>
@@ -561,10 +554,9 @@
Note how even if a particular clock becomes obsolete, the next clock in
line will have the same API. There is no new learning curve to come up.
The only source code changes will be simply changing the type of the clock.
- The same <code class="computeroutput"><span class="identifier">duration</span></code> and
- <code class="computeroutput"><span class="identifier">time_point</span></code> framework continues
- to work as new clocks are introduced. And multiple clocks are safely and
- easily handled within the same program.
+ The same link_text and <code class="computeroutput"><span class="identifier">time_point</span></code>
+ framework continues to work as new clocks are introduced. And multiple
+ clocks are safely and easily handled within the same program.
</p>
</div>
<div class="section" lang="en">
@@ -573,10 +565,9 @@
</h4></div></div></div>
<p>
A <code class="computeroutput"><span class="identifier">time_point</span></code> represents
- a point in time, as opposed to a <code class="computeroutput"><span class="identifier">duration</span></code>
- of time. Another way of saying the same thing, is that a <code class="computeroutput"><span class="identifier">time_point</span></code> represents an epoch plus or
- minus a <code class="computeroutput"><span class="identifier">duration</span></code>. Examples
- of <code class="computeroutput"><span class="identifier">time_point</span></code>s include:
+ a point in time, as opposed to a link_text of time. Another way of saying
+ the same thing, is that a <code class="computeroutput"><span class="identifier">time_point</span></code>
+ represents an epoch plus or minus a link_text. Examples of __time<span class="underline">point</span>_s include:
</p>
<div class="itemizedlist"><ul type="disc">
<li>
@@ -593,29 +584,28 @@
In each of the examples above, a different epoch is implied. Sometimes
an epoch has meaning for several millennia. Other times the meaning of
an epoch is lost after a while (such as the start of a timer, or when the
- computer booted). However, if two <code class="computeroutput"><span class="identifier">time_point</span></code>s
+ computer booted). However, if two __time<span class="underline">point</span>_s
are known to share the same epoch, they can be subtracted, yielding a valid
- <code class="computeroutput"><span class="identifier">duration</span></code>, even if the definition
- of the epoch no longer has meaning.
+ link_text, even if the definition of the epoch no longer has meaning.
</p>
<p>
In <span class="bold"><strong>Boost.Chrono</strong></span>, an epoch is a purely
abstract and unspecified concept. There is no type representing an epoch.
- It is simply an idea that relates (or doesn't) <code class="computeroutput"><span class="identifier">time_point</span></code>s
- to a clock, and in the case that they share a clock, <code class="computeroutput"><span class="identifier">time_point</span></code>s
- to one another. <code class="computeroutput"><span class="identifier">time_point</span></code>s
- associated with different clocks are generally not interoperable unless
- the relationship between the epochs associated with each clock is known.
- </p>
-<a name="boost_chrono.overview.motivation.time_point.so_what_exactly_is_a__code__phrase_role__identifier__time_point__phrase___code__and_how_do_i_use_one_"></a><h5>
-<a name="id4815754"></a>
- <a href="motivation.html#boost_chrono.overview.motivation.time_point.so_what_exactly_is_a__code__phrase_role__identifier__time_point__phrase___code__and_how_do_i_use_one_">So
+ It is simply an idea that relates (or doesn't) __time<span class="underline">point</span>_s
+ to a clock, and in the case that they share a clock, __time<span class="underline">point</span>_s
+ to one another. __time<span class="underline">point</span>_s associated
+ with different clocks are generally not interoperable unless the relationship
+ between the epochs associated with each clock is known.
+ </p>
+<a name="boost_chrono.overview.motivation.time_point.so_what_exactly_is_a___code__phrase_role__identifier__time_point__phrase___code__and_how_do_i_use_one_"></a><h5>
+<a name="id4815362"></a>
+ <a href="motivation.html#boost_chrono.overview.motivation.time_point.so_what_exactly_is_a___code__phrase_role__identifier__time_point__phrase___code__and_how_do_i_use_one_">So
What Exactly is a <code class="computeroutput"><span class="identifier">time_point</span></code>
and How Do I Use One?</a>
</h5>
<p>
A <code class="computeroutput"><span class="identifier">time_point</span></code> has a clock
- and a <code class="computeroutput"><span class="identifier">duration</span></code>.
+ and a link_text.
</p>
<pre class="programlisting"><span class="keyword">template</span> <span class="special"><</span><span class="keyword">class</span> <span class="identifier">Clock</span><span class="special">,</span> <span class="keyword">class</span> <span class="identifier">Duration</span> <span class="special">=</span> <span class="keyword">typename</span> <span class="identifier">Clock</span><span class="special">::</span><span class="identifier">duration</span><span class="special">></span> <span class="keyword">class</span> <span class="identifier">time_point</span><span class="special">;</span>
</pre>
@@ -626,9 +616,9 @@
</p>
<div class="orderedlist"><ol type="1">
<li>
- Because <code class="computeroutput"><span class="identifier">time_point</span></code>s originating
+ Because __time<span class="underline">point</span>_s originating
from different clocks have different types, the compiler can be instructed
- to fail if incompatible <code class="computeroutput"><span class="identifier">time_point</span></code>s
+ to fail if incompatible __time<span class="underline">point</span>_s
are used in inappropriate ways.
</li>
<li>
@@ -639,17 +629,17 @@
</li>
</ol></div>
<p>
- A <code class="computeroutput"><span class="identifier">time_point</span></code>'s <code class="computeroutput"><span class="identifier">duration</span></code> is stored as the only data member
- of the <code class="computeroutput"><span class="identifier">time_point</span></code>. Thus
- <code class="computeroutput"><span class="identifier">time_point</span></code>s and their corresponding
- <code class="computeroutput"><span class="identifier">duration</span></code> have exactly the
- same layout. But they have very different meanings. For example, it is
- one thing to say I want to sleep for 3 minutes. It is a completely different
- thing to say I want to sleep until 3 minutes past the time I started that
- timer (unless you just happened to start that timer now). Both meanings
- (and options for sleeping) have great practical value in common use cases
- for sleeping, waiting on a condition variable, and waiting for a mutex's
- lock. These same concepts and tools are found (for example) in Ada.
+ A <code class="computeroutput"><span class="identifier">time_point</span></code>'s link_text
+ is stored as the only data member of the <code class="computeroutput"><span class="identifier">time_point</span></code>.
+ Thus __time<span class="underline">point</span>_s and their corresponding
+ link_text have exactly the same layout. But they have very different meanings.
+ For example, it is one thing to say I want to sleep for 3 minutes. It is
+ a completely different thing to say I want to sleep until 3 minutes past
+ the time I started that timer (unless you just happened to start that timer
+ now). Both meanings (and options for sleeping) have great practical value
+ in common use cases for sleeping, waiting on a condition variable, and
+ waiting for a mutex's lock. These same concepts and tools are found (for
+ example) in Ada.
</p>
<p>
A timer example:
@@ -664,16 +654,14 @@
<span class="special">}</span>
</pre>
<p>
- Note that if one is using the <code class="computeroutput"><span class="identifier">duration</span></code>
- between two clock <code class="computeroutput"><span class="identifier">time_point</span></code>s
- in a way where the precision of the <code class="computeroutput"><span class="identifier">duration</span></code>
- matters, it is good practice to convert the clock's native <code class="computeroutput"><span class="identifier">duration</span></code> to a known <code class="computeroutput"><span class="identifier">duration</span></code>.
- This insulates the code from future changes which may be made to the clock's
- native precision in the future. For example monotonic_clock could easily
- be based on the clock speed of the cpu. When you upgrade to a faster machine,
- you do not want your code that assumed a certain tick period of this clock
- to start experiencing run time failures because your timing code has silently
- changed meaning.
+ Note that if one is using the link_text between two clock __time<span class="underline">point</span>_s in a way where the precision of the
+ link_text matters, it is good practice to convert the clock's native link_text
+ to a known link_text. This insulates the code from future changes which
+ may be made to the clock's native precision in the future. For example
+ monotonic_clock could easily be based on the clock speed of the cpu. When
+ you upgrade to a faster machine, you do not want your code that assumed
+ a certain tick period of this clock to start experiencing run time failures
+ because your timing code has silently changed meaning.
</p>
<p>
A delay loop example:
@@ -733,7 +721,7 @@
<span class="number">0.017</span><span class="identifier">s</span>
</pre>
<a name="boost_chrono.overview.motivation.stopwatches.stopwatches_accumulation_and_statistics"></a><h5>
-<a name="id4816875"></a>
+<a name="id4816406"></a>
<a href="motivation.html#boost_chrono.overview.motivation.stopwatches.stopwatches_accumulation_and_statistics">Stopwatches
accumulation and statistics</a>
</h5>
@@ -770,7 +758,7 @@
<pre class="programlisting"><span class="number">3</span> <span class="identifier">times</span><span class="special">,</span> <span class="identifier">sum</span><span class="special">=</span><span class="number">0.034</span><span class="identifier">s</span><span class="special">,</span> <span class="identifier">min</span><span class="special">=</span><span class="number">0.006</span><span class="identifier">s</span><span class="special">,</span> <span class="identifier">max</span><span class="special">=</span><span class="number">0.017</span><span class="identifier">s</span><span class="special">,</span> <span class="identifier">mean</span><span class="special">=</span><span class="number">0.011</span><span class="identifier">s</span>
</pre>
<a name="boost_chrono.overview.motivation.stopwatches.wall_clock_versus_system_and_user_time"></a><h5>
-<a name="id4817393"></a>
+<a name="id4816924"></a>
<a href="motivation.html#boost_chrono.overview.motivation.stopwatches.wall_clock_versus_system_and_user_time">Wall
clock versus system and user time</a>
</h5>
@@ -826,7 +814,7 @@
</span><span class="special">}</span>
</pre>
<a name="boost_chrono.overview.motivation.stopwatches.how_reliable_are_these_measures_"></a><h5>
-<a name="id4817780"></a>
+<a name="id4817311"></a>
<a href="motivation.html#boost_chrono.overview.motivation.stopwatches.how_reliable_are_these_measures_">How
reliable are these measures?</a>
</h5>
Modified: sandbox/chrono/libs/chrono/doc/html/boost_chrono/reference/cpp0x.html
==============================================================================
--- sandbox/chrono/libs/chrono/doc/html/boost_chrono/reference/cpp0x.html (original)
+++ sandbox/chrono/libs/chrono/doc/html/boost_chrono/reference/cpp0x.html 2010-06-26 11:18:46 EDT (Sat, 26 Jun 2010)
@@ -32,10 +32,16 @@
<div class="toc"><dl>
<dt><span class="section"><a href="cpp0x.html#boost_chrono.reference.cpp0x.common_type_hpp"> Header
<code class="computeroutput"><span class="special"><</span><span class="identifier">boost</span><span class="special">/</span><span class="identifier">type_traits</span><span class="special">/</span><span class="identifier">common_type</span><span class="special">.</span><span class="identifier">hpp</span><span class="special">></span></code></a></span></dt>
-<dd><dl><dt><span class="section"><a href="cpp0x.html#boost_chrono.reference.cpp0x.common_type_hpp.common_type">
- Class Template <code class="computeroutput"><span class="identifier">common_type</span></code></a></span></dt></dl></dd>
+<dd><dl>
+<dt><span class="section"><a href="cpp0x.html#boost_chrono.reference.cpp0x.common_type_hpp.macros">
+ Configuration macros</a></span></dt>
+<dt><span class="section"><a href="cpp0x.html#boost_chrono.reference.cpp0x.common_type_hpp.common_type">
+ Class Template link_text</a></span></dt>
+</dl></dd>
<dt><span class="section"> Header <boost/ratio.hpp>
</span></dt>
<dd><dl>
+<dt><span class="section"><a href="cpp0x.html#boost_chrono.reference.cpp0x.ratio_hpp.macros"> Configuration
+ macros</a></span></dt>
<dt><span class="section"><a href="cpp0x.html#boost_chrono.reference.cpp0x.ratio_hpp.ratio"> Class
Template <code class="computeroutput"><span class="identifier">ratio</span><span class="special"><></span></code></a></span></dt>
<dt><span class="section"><a href="cpp0x.html#boost_chrono.reference.cpp0x.ratio_hpp.ratio_arithmetic">
@@ -49,19 +55,21 @@
<dt><span class="section"><a href="cpp0x.html#boost_chrono.reference.cpp0x.chrono_chrono_hpp"> Header
<code class="computeroutput"><span class="special"><</span><span class="identifier">boost</span><span class="special">/</span><span class="identifier">chrono</span><span class="special">/</span><span class="identifier">chrono</span><span class="special">.</span><span class="identifier">hpp</span><span class="special">></span></code></a></span></dt>
<dd><dl>
+<dt><span class="section"><a href="cpp0x.html#boost_chrono.reference.cpp0x.chrono_chrono_hpp.macros">
+ Configuration macros</a></span></dt>
<dt><span class="section"><a href="cpp0x.html#boost_chrono.reference.cpp0x.chrono_chrono_hpp.clock">
<code class="computeroutput"><span class="identifier">Clock</span></code> Requirements</a></span></dt>
<dt><span class="section"><a href="cpp0x.html#boost_chrono.reference.cpp0x.chrono_chrono_hpp.time_related_traits">Time-related
traits</a></span></dt>
-<dt><span class="section"><a href="cpp0x.html#boost_chrono.reference.cpp0x.chrono_chrono_hpp.class_template__duration_">Class
- template <code class="computeroutput"><span class="identifier">duration</span></code></a></span></dt>
+<dt><span class="section"><a href="cpp0x.html#boost_chrono.reference.cpp0x.chrono_chrono_hpp.class_template___duration__">Class
+ template link_text</a></span></dt>
<dt><span class="section"><a href="cpp0x.html#boost_chrono.reference.cpp0x.chrono_chrono_hpp.duration_non_member_arithmetic">duration
non-member arithmetic</a></span></dt>
<dt><span class="section"><a href="cpp0x.html#boost_chrono.reference.cpp0x.chrono_chrono_hpp.duration_comparaisons">duration
comparaisons</a></span></dt>
<dt><span class="section"><a href="cpp0x.html#boost_chrono.reference.cpp0x.chrono_chrono_hpp.duration_cast">
Non-Member function <code class="computeroutput"><span class="identifier">duration_cast</span><span class="special">(</span><span class="identifier">duration</span><span class="special">)</span></code></a></span></dt>
-<dt><span class="section"><a href="cpp0x.html#boost_chrono.reference.cpp0x.chrono_chrono_hpp.class_template__time_point_">Class
+<dt><span class="section"><a href="cpp0x.html#boost_chrono.reference.cpp0x.chrono_chrono_hpp.class_template___time_point__">Class
template <code class="computeroutput"><span class="identifier">time_point</span></code></a></span></dt>
<dt><span class="section"><a href="cpp0x.html#boost_chrono.reference.cpp0x.chrono_chrono_hpp.time_point_non_member_arithmetic">time_point
non-member arithmetic</a></span></dt>
@@ -85,23 +93,76 @@
<boost/type_traits/common_type.hpp>"> Header
<code class="computeroutput"><span class="special"><</span><span class="identifier">boost</span><span class="special">/</span><span class="identifier">type_traits</span><span class="special">/</span><span class="identifier">common_type</span><span class="special">.</span><span class="identifier">hpp</span><span class="special">></span></code></a>
</h4></div></div></div>
-<div class="toc"><dl><dt><span class="section"><a href="cpp0x.html#boost_chrono.reference.cpp0x.common_type_hpp.common_type">
- Class Template <code class="computeroutput"><span class="identifier">common_type</span></code></a></span></dt></dl></div>
-<pre class="programlisting"><span class="keyword">namespace</span> <span class="identifier">boost</span> <span class="special">{</span>
+<div class="toc"><dl>
+<dt><span class="section"><a href="cpp0x.html#boost_chrono.reference.cpp0x.common_type_hpp.macros">
+ Configuration macros</a></span></dt>
+<dt><span class="section"><a href="cpp0x.html#boost_chrono.reference.cpp0x.common_type_hpp.common_type">
+ Class Template link_text</a></span></dt>
+</dl></div>
+<pre class="programlisting"><span class="preprocessor">#define</span> <span class="identifier">BOOST_COMMON_TYPE_ARITY</span>
+<span class="preprocessor">#define</span> <span class="identifier">BOOST_COMMON_TYPE_USES_STATIC_ASSERT</span>
+<span class="preprocessor">#define</span> <span class="identifier">BOOST_COMMON_TYPE_USES_MPL_ASSERT</span>
+<span class="preprocessor">#define</span> <span class="identifier">BOOST_COMMON_TYPE_USES_ARRAY_ASSERT</span>
+
+<span class="preprocessor">#define</span> <span class="identifier">BOOST_COMMON_TYPE_MUST_BE_A_COMPLE_TYPE</span>
+
+<span class="keyword">namespace</span> <span class="identifier">boost</span> <span class="special">{</span>
<span class="keyword">template</span> <span class="special"><</span><span class="keyword">class</span> <span class="special">...</span><span class="identifier">T</span><span class="special">></span> <span class="keyword">struct</span> <span class="identifier">common_type</span><span class="special">;</span>
<span class="special">}</span>
</pre>
<div class="section" lang="en">
<div class="titlepage"><div><div><h5 class="title">
+<a name="boost_chrono.reference.cpp0x.common_type_hpp.macros"></a><a href="cpp0x.html#boost_chrono.reference.cpp0x.common_type_hpp.macros" title="
+ Configuration macros">
+ Configuration macros</a>
+</h5></div></div></div>
+<p>
+ When BOOST_NO_VARIADIC_TEMPLATES is defined BOOST_COMMON_TYPE_ARITY gives
+ the maximum number of template parameters for link_text.
+ </p>
+<p>
+ When BOOST_NO_STATIC_ASSERT is defined, the user can select the way static
+ assertions are reported. Define
+ </p>
+<div class="itemizedlist"><ul type="disc">
+<li>
+ BOOST_COMMON_TYPE_USES_STATIC_ASSERT: define it if you want to use
+ Boost.StaticAssert
+ </li>
+<li>
+ BOOST_COMMON_TYPE_USES_MPL_ASSERT: define it if you want to use Boost.MPL
+ static asertions
+ </li>
+<li>
+ BOOST_COMMON_TYPE_USES_ARRAY_ASSERT: define it if you want to use internal
+ static asertions
+ </li>
+<li>
+ nothing if you don't want static asertions
+ </li>
+</ul></div>
+<p>
+ When BOOST_COMMON_TYPE_USES_MPL_ASSERT is not defined the following symbols
+ are defined as
+ </p>
+<pre class="programlisting"><span class="preprocessor">#define</span> <span class="identifier">BOOST_COMMON_TYPE_MUST_BE_A_COMPLE_TYPE</span> <span class="special">\</span>
+ <span class="string">"must be complete type"</span>
+</pre>
+<p>
+ Depending on the static assertion used system you will have an hint of
+ the failing assertion either through the symbol or through the texte.
+ </p>
+</div>
+<div class="section" lang="en">
+<div class="titlepage"><div><div><h5 class="title">
<a name="boost_chrono.reference.cpp0x.common_type_hpp.common_type"></a><a href="cpp0x.html#boost_chrono.reference.cpp0x.common_type_hpp.common_type" title="
- Class Template common_type">
- Class Template <code class="computeroutput"><span class="identifier">common_type</span></code></a>
+ Class Template link_text">
+ Class Template link_text</a>
</h5></div></div></div>
<p>
- <code class="computeroutput"><span class="identifier">common_type</span></code> is a facility
- which is useful in specifying the type of the result of functions and
- operators which take a variety of types (e.g. "mixed mode"
- complex arithmetic).
+ link_text is a facility which is useful in specifying the type of the
+ result of functions and operators which take a variety of types (e.g.
+ "mixed mode" complex arithmetic).
</p>
<p>
The nested typedef <code class="computeroutput"><span class="identifier">common_type</span><span class="special">::</span><span class="identifier">type</span></code>
@@ -133,8 +194,7 @@
</p>
<p>
<span class="bold"><strong>Note:</strong></span> Such specializations are required
- when only explicit conversions are desired among the <code class="computeroutput"><span class="identifier">common_type</span></code>
- arguments.
+ when only explicit conversions are desired among the link_text arguments.
</p>
</div>
</div>
@@ -143,6 +203,8 @@
<a name="boost_chrono.reference.cpp0x.ratio_hpp"></a> Header <boost/ratio.hpp>
</h4></div></div></div>
<div class="toc"><dl>
+<dt><span class="section"><a href="cpp0x.html#boost_chrono.reference.cpp0x.ratio_hpp.macros"> Configuration
+ macros</a></span></dt>
<dt><span class="section"><a href="cpp0x.html#boost_chrono.reference.cpp0x.ratio_hpp.ratio"> Class
Template <code class="computeroutput"><span class="identifier">ratio</span><span class="special"><></span></code></a></span></dt>
<dt><span class="section"><a href="cpp0x.html#boost_chrono.reference.cpp0x.ratio_hpp.ratio_arithmetic">
@@ -161,7 +223,20 @@
254/10000 meters - which <code class="computeroutput"><span class="identifier">ratio</span></code>
will reduce to 127/5000 meters).
</p>
-<pre class="programlisting"><span class="keyword">namespace</span> <span class="identifier">boost</span> <span class="special">{</span>
+<pre class="programlisting"><span class="preprocessor">#define</span> <span class="identifier">BOOST_RATIO_USES_STATIC_ASSERT</span>
+<span class="preprocessor">#define</span> <span class="identifier">BOOST_RATIO_USES_MPL_ASSERT</span>
+<span class="preprocessor">#define</span> <span class="identifier">BOOST_RATIO_USES_ARRAY_ASSERT</span>
+
+<span class="preprocessor">#define</span> <span class="identifier">BOOST_RATIO_OVERFLOW_IN_ADD</span>
+<span class="preprocessor">#define</span> <span class="identifier">BOOST_RATIO_OVERFLOW_IN_ADD</span>
+<span class="preprocessor">#define</span> <span class="identifier">BOOST_RATIO_OVERFLOW_IN_SUB</span>
+<span class="preprocessor">#define</span> <span class="identifier">BOOST_RATIO_OVERFLOW_IN_MUL</span>
+<span class="preprocessor">#define</span> <span class="identifier">BOOST_RATIO_OVERFLOW_IN_DIV</span>
+<span class="preprocessor">#define</span> <span class="identifier">BOOST_RATIO_RATIO_NUMERATOR_IS_OUT_OF_RANGE</span>
+<span class="preprocessor">#define</span> <span class="identifier">BOOST_RATIO_RATIO_DIVIDE_BY_0</span>
+<span class="preprocessor">#define</span> <span class="identifier">BOOST_RATIO_RATIO_DENOMINATOR_IS_OUT_OF_RANGE</span>
+
+<span class="keyword">namespace</span> <span class="identifier">boost</span> <span class="special">{</span>
<span class="keyword">template</span> <span class="special"><</span><span class="identifier">boost</span><span class="special">::</span><span class="identifier">intmax_t</span> <span class="identifier">N</span><span class="special">,</span> <span class="identifier">boost</span><span class="special">::</span><span class="identifier">intmax_t</span> <span class="identifier">D</span> <span class="special">=</span> <span class="number">1</span><span class="special">></span> <span class="keyword">class</span> <span class="identifier">ratio</span><span class="special">;</span>
@@ -200,6 +275,50 @@
</pre>
<div class="section" lang="en">
<div class="titlepage"><div><div><h5 class="title">
+<a name="boost_chrono.reference.cpp0x.ratio_hpp.macros"></a><a href="cpp0x.html#boost_chrono.reference.cpp0x.ratio_hpp.macros" title=" Configuration
+ macros"> Configuration
+ macros</a>
+</h5></div></div></div>
+<p>
+ When BOOST_NO_STATIC_ASSERT is defined, the user can select the way static
+ assertions are reported. Define
+ </p>
+<div class="itemizedlist"><ul type="disc">
+<li>
+ BOOST_RATIO_USES_STATIC_ASSERT: define it if you want to use Boost.StaticAssert
+ </li>
+<li>
+ BOOST_RATIO_USES_MPL_ASSERT: define it if you want to use Boost.MPL
+ static asertions
+ </li>
+<li>
+ BOOST_RATIO_USES_ARRAY_ASSERT: define it if you want to use internal
+ static asertions
+ </li>
+<li>
+ nothing if you don't want static asertions
+ </li>
+</ul></div>
+<p>
+ When BOOST_RATIO_USES_MPL_ASSERT is not defined the following symbols
+ are defined as
+ </p>
+<pre class="programlisting"><span class="preprocessor">#define</span> <span class="identifier">BOOST_RATIO_OVERFLOW_IN_ADD</span> <span class="string">"overflow in ratio add"</span>
+<span class="preprocessor">#define</span> <span class="identifier">BOOST_RATIO_OVERFLOW_IN_ADD</span> <span class="string">"overflow in ratio add"</span>
+<span class="preprocessor">#define</span> <span class="identifier">BOOST_RATIO_OVERFLOW_IN_SUB</span> <span class="string">"overflow in ratio sub"</span>
+<span class="preprocessor">#define</span> <span class="identifier">BOOST_RATIO_OVERFLOW_IN_MUL</span> <span class="string">"overflow in ratio mul"</span>
+<span class="preprocessor">#define</span> <span class="identifier">BOOST_RATIO_OVERFLOW_IN_DIV</span> <span class="string">"overflow in ratio div"</span>
+<span class="preprocessor">#define</span> <span class="identifier">BOOST_RATIO_RATIO_NUMERATOR_IS_OUT_OF_RANGE</span> <span class="string">"ratio numerator is out of range"</span>
+<span class="preprocessor">#define</span> <span class="identifier">BOOST_RATIO_RATIO_DIVIDE_BY_0</span> <span class="string">"ratio divide by 0"</span>
+<span class="preprocessor">#define</span> <span class="identifier">BOOST_RATIO_RATIO_DENOMINATOR_IS_OUT_OF_RANGE</span> <span class="string">"ratio denominator is out of range"</span>
+</pre>
+<p>
+ Depending on the static assertion used system you will have an hint of
+ the failing assertion either through the symbol or through the texte.
+ </p>
+</div>
+<div class="section" lang="en">
+<div class="titlepage"><div><div><h5 class="title">
<a name="boost_chrono.reference.cpp0x.ratio_hpp.ratio"></a><a href="cpp0x.html#boost_chrono.reference.cpp0x.ratio_hpp.ratio" title=" Class
Template ratio<>"> Class
Template <code class="computeroutput"><span class="identifier">ratio</span><span class="special"><></span></code></a>
@@ -437,19 +556,21 @@
<code class="computeroutput"><span class="special"><</span><span class="identifier">boost</span><span class="special">/</span><span class="identifier">chrono</span><span class="special">/</span><span class="identifier">chrono</span><span class="special">.</span><span class="identifier">hpp</span><span class="special">></span></code></a>
</h4></div></div></div>
<div class="toc"><dl>
+<dt><span class="section"><a href="cpp0x.html#boost_chrono.reference.cpp0x.chrono_chrono_hpp.macros">
+ Configuration macros</a></span></dt>
<dt><span class="section"><a href="cpp0x.html#boost_chrono.reference.cpp0x.chrono_chrono_hpp.clock">
<code class="computeroutput"><span class="identifier">Clock</span></code> Requirements</a></span></dt>
<dt><span class="section"><a href="cpp0x.html#boost_chrono.reference.cpp0x.chrono_chrono_hpp.time_related_traits">Time-related
traits</a></span></dt>
-<dt><span class="section"><a href="cpp0x.html#boost_chrono.reference.cpp0x.chrono_chrono_hpp.class_template__duration_">Class
- template <code class="computeroutput"><span class="identifier">duration</span></code></a></span></dt>
+<dt><span class="section"><a href="cpp0x.html#boost_chrono.reference.cpp0x.chrono_chrono_hpp.class_template___duration__">Class
+ template link_text</a></span></dt>
<dt><span class="section"><a href="cpp0x.html#boost_chrono.reference.cpp0x.chrono_chrono_hpp.duration_non_member_arithmetic">duration
non-member arithmetic</a></span></dt>
<dt><span class="section"><a href="cpp0x.html#boost_chrono.reference.cpp0x.chrono_chrono_hpp.duration_comparaisons">duration
comparaisons</a></span></dt>
<dt><span class="section"><a href="cpp0x.html#boost_chrono.reference.cpp0x.chrono_chrono_hpp.duration_cast">
Non-Member function <code class="computeroutput"><span class="identifier">duration_cast</span><span class="special">(</span><span class="identifier">duration</span><span class="special">)</span></code></a></span></dt>
-<dt><span class="section"><a href="cpp0x.html#boost_chrono.reference.cpp0x.chrono_chrono_hpp.class_template__time_point_">Class
+<dt><span class="section"><a href="cpp0x.html#boost_chrono.reference.cpp0x.chrono_chrono_hpp.class_template___time_point__">Class
template <code class="computeroutput"><span class="identifier">time_point</span></code></a></span></dt>
<dt><span class="section"><a href="cpp0x.html#boost_chrono.reference.cpp0x.chrono_chrono_hpp.time_point_non_member_arithmetic">time_point
non-member arithmetic</a></span></dt>
@@ -464,8 +585,15 @@
<dt><span class="section"><a href="cpp0x.html#boost_chrono.reference.cpp0x.chrono_chrono_hpp.class__high_resolution_clock_">Class
<code class="computeroutput"><span class="identifier">high_resolution_clock</span></code></a></span></dt>
</dl></div>
-<pre class="programlisting"><span class="preprocessor">#define</span> <span class="identifier">BOOST_SYSTEM_CLOCK_DURATION</span>
-<span class="preprocessor">#define</span> <span class="identifier">BOOST_CHRONO_HAS_CLOCK_MONOTONIC</span>
+<pre class="programlisting"><span class="preprocessor">#define</span> <span class="identifier">BOOST_CHRONO_HAS_CLOCK_MONOTONIC</span>
+
+<span class="preprocessor">#define</span> <span class="identifier">BOOST_CHRONO_A_DURATION_REPRESENTATION_CAN_NOT_BE_A_DURATION</span> <span class="special">\</span>
+ <span class="string">"A duration representation can not be a duration"</span>
+<span class="preprocessor">#define</span> <span class="identifier">BOOST_CHRONO_SECOND_TEMPLATE_PARAMETER_OF_DURATION_MUST_BE_A_STD_RATIO</span> <span class="special">\</span>
+ <span class="string">"Second template parameter of duration must be a std::ratio"</span>
+<span class="preprocessor">#define</span> <span class="identifier">BOOST_CHRONO_DURATION_PERIOD_MUST_BE_POSITIVE</span> <span class="special">\</span>
+ <span class="string">"duration period must be positive"</span>
+<span class="preprocessor">#define</span> <span class="identifier">BOOST_CHRONO_SECOND_TEMPLATE_PARAMETER_OF_TIME_POINT_MUST_BE_A_BOOST_CHRONO_DURATION</span> <span class="special">\</span>
<span class="keyword">namespace</span> <span class="identifier">boost</span> <span class="special">{</span>
<span class="keyword">namespace</span> <span class="identifier">chrono</span> <span class="special">{</span>
@@ -598,14 +726,58 @@
</pre>
<div class="section" lang="en">
<div class="titlepage"><div><div><h5 class="title">
+<a name="boost_chrono.reference.cpp0x.chrono_chrono_hpp.macros"></a><a href="cpp0x.html#boost_chrono.reference.cpp0x.chrono_chrono_hpp.macros" title="
+ Configuration macros">
+ Configuration macros</a>
+</h5></div></div></div>
+<p>
+ When BOOST_NO_STATIC_ASSERT is defined, the user can select the way static
+ assertions are reported. Define
+ </p>
+<div class="itemizedlist"><ul type="disc">
+<li>
+ BOOST_CHRONO_USES_STATIC_ASSERT: define it if you want to use Boost.StaticAssert
+ </li>
+<li>
+ BOOST_CHRONO_USES_MPL_ASSERT: define it if you want to use Boost.MPL
+ static asertions
+ </li>
+<li>
+ BOOST_CHRONO_USES_ARRAY_ASSERT: define it if you want to use internal
+ static asertions
+ </li>
+<li>
+ nothing if you don't want static asertions
+ </li>
+</ul></div>
+<p>
+ When BOOST_CHRONO_USES_MPL_ASSERT is not defined the following symbols
+ are defined as
+ </p>
+<pre class="programlisting"><span class="preprocessor">#define</span> <span class="identifier">BOOST_CHRONO_A_DURATION_REPRESENTATION_CAN_NOT_BE_A_DURATION</span> <span class="special">\</span>
+ <span class="string">"A duration representation can not be a duration"</span>
+<span class="preprocessor">#define</span> <span class="identifier">BOOST_CHRONO_SECOND_TEMPLATE_PARAMETER_OF_DURATION_MUST_BE_A_STD_RATIO</span> <span class="special">\</span>
+ <span class="string">"Second template parameter of duration must be a std::ratio"</span>
+<span class="preprocessor">#define</span> <span class="identifier">BOOST_CHRONO_DURATION_PERIOD_MUST_BE_POSITIVE</span> <span class="special">\</span>
+ <span class="string">"duration period must be positive"</span>
+<span class="preprocessor">#define</span> <span class="identifier">BOOST_CHRONO_SECOND_TEMPLATE_PARAMETER_OF_TIME_POINT_MUST_BE_A_BOOST_CHRONO_DURATION</span> <span class="special">\</span>
+ <span class="string">"Second template parameter of time_point must be a boost::chrono::duration"</span>
+</pre>
+<p>
+ Depending on the static assertion used system you will have an hint of
+ the failing assertion either through the symbol or through the texte.
+ </p>
+</div>
+<div class="section" lang="en">
+<div class="titlepage"><div><div><h5 class="title">
<a name="boost_chrono.reference.cpp0x.chrono_chrono_hpp.clock"></a><a href="cpp0x.html#boost_chrono.reference.cpp0x.chrono_chrono_hpp.clock" title="
Clock Requirements">
<code class="computeroutput"><span class="identifier">Clock</span></code> Requirements</a>
</h5></div></div></div>
<p>
- A clock represents a bundle consisting of a native <code class="computeroutput"><span class="identifier">duration</span></code>,
- a native <code class="computeroutput"><span class="identifier">time_point</span></code>,
- and a function <code class="computeroutput"><span class="identifier">now</span><span class="special">()</span></code>
+ A clock represents a bundle consisting of a native link_text, a native
+ <code class="computeroutput"><span class="identifier">time_point</span></code>, and a function
+ <code class="computeroutput"><span class="identifier">now</span><span class="special">()</span></code>
to get the current <code class="computeroutput"><span class="identifier">time_point</span></code>.
A clock must meet the requirements in the following Table.
</p>
@@ -619,7 +791,7 @@
and both of these calls happen before <code class="computeroutput"><span class="identifier">C1</span><span class="special">::</span><span class="identifier">time_point</span><span class="special">::</span><span class="identifier">max</span><span class="special">()</span></code>.
</p>
<div class="table">
-<a name="id4866118"></a><p class="title"><b>Table 1. Clock Requirements</b></p>
+<a name="id4866400"></a><p class="title"><b>Table 1. Clock Requirements</b></p>
<table class="table" summary="Clock Requirements">
<colgroup>
<col>
@@ -657,8 +829,7 @@
</td>
<td>
<p>
- The representation type of the native <code class="computeroutput"><span class="identifier">duration</span></code>
- and <code class="computeroutput"><span class="identifier">time_point</span></code>.
+ The representation type of the native link_text and <code class="computeroutput"><span class="identifier">time_point</span></code>.
</p>
</td>
</tr>
@@ -693,8 +864,7 @@
</td>
<td>
<p>
- The native <code class="computeroutput"><span class="identifier">duration</span></code>
- type of the <code class="computeroutput"><span class="identifier">clock</span></code>.
+ The native link_text type of the <code class="computeroutput"><span class="identifier">clock</span></code>.
</p>
</td>
</tr>
@@ -716,7 +886,7 @@
type of the <code class="computeroutput"><span class="identifier">clock</span></code>.
Different clocks are permitted to share a <code class="computeroutput"><span class="identifier">time_point</span></code>
definition if it is valid to compare their time_points by comparing
- their respective <code class="computeroutput"><span class="identifier">duration</span></code>s.
+ their respective <span class="underline">_duration</span>_s.
<code class="computeroutput"><span class="identifier">C1</span></code> and <code class="computeroutput"><span class="identifier">C2</span></code> must refer to the same
epoch.
</p>
@@ -787,7 +957,8 @@
Metafunction <code class="computeroutput"><span class="identifier">treat_as_floating_point</span><span class="special"><></span></code></a></span></dt>
<dt><span class="section"><a href="cpp0x.html#boost_chrono.reference.cpp0x.chrono_chrono_hpp.time_related_traits.duration_values">
Class template <code class="computeroutput"><span class="identifier">duration_values</span></code></a></span></dt>
-<dt><span class="section">common_type
specializations</span></dt>
+<dt><span class="section"><a href="cpp0x.html#boost_chrono.reference.cpp0x.chrono_chrono_hpp.time_related_traits.__common_type___specializations">
+ link_text specializations</a></span></dt>
</dl></div>
<div class="section" lang="en">
<div class="titlepage"><div><div><h6 class="title">
@@ -799,21 +970,17 @@
<span class="special">:</span> <span class="identifier">boost</span><span class="special">::</span><span class="identifier">is_floating_point</span><span class="special"><</span><span class="identifier">Rep</span><span class="special">></span> <span class="special">{};</span>
</pre>
<p>
- The <code class="computeroutput"><span class="identifier">duration</span></code> template
- uses the <code class="computeroutput"><span class="identifier">treat_as_floating_point</span></code>
- trait to help determine if a <code class="computeroutput"><span class="identifier">duration</span></code>
- with one tick period can be converted to another <code class="computeroutput"><span class="identifier">duration</span></code>
- with a different tick period. If <code class="computeroutput"><span class="identifier">treat_as_floating_point</span><span class="special"><</span><span class="identifier">Rep</span><span class="special">>::</span><span class="identifier">value</span></code>
- is <code class="computeroutput"><span class="keyword">true</span></code>, then <code class="computeroutput"><span class="identifier">Rep</span></code> is a floating point type and
- implicit conversions are allowed among <code class="computeroutput"><span class="identifier">duration</span></code>s.
+ The link_text template uses the <code class="computeroutput"><span class="identifier">treat_as_floating_point</span></code>
+ trait to help determine if a link_text with one tick period can be
+ converted to another link_text with a different tick period. If <code class="computeroutput"><span class="identifier">treat_as_floating_point</span><span class="special"><</span><span class="identifier">Rep</span><span class="special">>::</span><span class="identifier">value</span></code> is <code class="computeroutput"><span class="keyword">true</span></code>,
+ then <code class="computeroutput"><span class="identifier">Rep</span></code> is a floating
+ point type and implicit conversions are allowed among <span class="underline">_duration</span>_s.
Otherwise, the implicit convertibility depends on the tick periods
- of the <code class="computeroutput"><span class="identifier">duration</span></code>s. If
- <code class="computeroutput"><span class="identifier">Rep</span></code> is a class type
- which emulates a floating point type, the author of <code class="computeroutput"><span class="identifier">Rep</span></code>
+ of the <span class="underline">_duration</span>_s. If <code class="computeroutput"><span class="identifier">Rep</span></code> is a class type which emulates
+ a floating point type, the author of <code class="computeroutput"><span class="identifier">Rep</span></code>
can specialize <code class="computeroutput"><span class="identifier">treat_as_floating_point</span></code>
- so that <code class="computeroutput"><span class="identifier">duration</span></code> will
- treat this <code class="computeroutput"><span class="identifier">Rep</span></code> as if
- it were a floating point type. Otherwise <code class="computeroutput"><span class="identifier">Rep</span></code>
+ so that link_text will treat this <code class="computeroutput"><span class="identifier">Rep</span></code>
+ as if it were a floating point type. Otherwise <code class="computeroutput"><span class="identifier">Rep</span></code>
is assumed to be an integral type, or a class emulating an integral
type.
</p>
@@ -842,9 +1009,8 @@
<span class="special">};</span>
</pre>
<p>
- The <code class="computeroutput"><span class="identifier">duration</span></code> template
- uses the <code class="computeroutput"><span class="identifier">duration_values</span></code>
- trait to construct special values of the <code class="computeroutput"><span class="identifier">duration</span></code>s
+ The link_text template uses the <code class="computeroutput"><span class="identifier">duration_values</span></code>
+ trait to construct special values of the <span class="underline">_duration</span>_s
representation (<code class="computeroutput"><span class="identifier">Rep</span></code>).
This is done because the representation might be a class type with
behavior which requires some other implementation to return these special
@@ -906,7 +1072,9 @@
</div>
<div class="section" lang="en">
<div class="titlepage"><div><div><h6 class="title">
-<a name="boost_chrono.reference.cpp0x.chrono_chrono_hpp.time_related_traits._common_type__specializations"></a>common_type
specializations
+<a name="boost_chrono.reference.cpp0x.chrono_chrono_hpp.time_related_traits.__common_type___specializations"></a><a href="cpp0x.html#boost_chrono.reference.cpp0x.chrono_chrono_hpp.time_related_traits.__common_type___specializations" title="
+ link_text specializations">
+ link_text specializations</a>
</h6></div></div></div>
<pre class="programlisting"><span class="keyword">template</span> <span class="special"><</span><span class="keyword">class</span> <span class="identifier">Rep1</span><span class="special">,</span> <span class="keyword">class</span> <span class="identifier">Period1</span><span class="special">,</span> <span class="keyword">class</span> <span class="identifier">Rep2</span><span class="special">,</span> <span class="keyword">class</span> <span class="identifier">Period2</span><span class="special">></span>
<span class="keyword">struct</span> <span class="identifier">common_type</span><span class="special"><</span><span class="identifier">chrono</span><span class="special">::</span><span class="identifier">duration</span><span class="special"><</span><span class="identifier">Rep1</span><span class="special">,</span> <span class="identifier">Period1</span><span class="special">>,</span> <span class="identifier">chrono</span><span class="special">::</span><span class="identifier">duration</span><span class="special"><</span><span class="identifier">Rep2</span><span class="special">,</span> <span class="identifier">Period2</span><span class="special">></span> <span class="special">></span>
@@ -915,8 +1083,7 @@
<span class="special">};</span>
</pre>
<p>
- The period of the <code class="computeroutput"><span class="identifier">duration</span></code>
- indicated by this specialization of <code class="computeroutput"><span class="identifier">common_type</span></code>
+ The period of the link_text indicated by this specialization of link_text
is the greatest common divisor of <code class="computeroutput"><span class="identifier">Period1</span></code>
and <code class="computeroutput"><span class="identifier">Period2</span></code>. This can
be computed by forming a <code class="computeroutput"><span class="identifier">ratio</span></code>
@@ -925,13 +1092,13 @@
of <code class="computeroutput"><span class="identifier">Period1</span><span class="special">::</span><span class="identifier">den</span></code> and <code class="computeroutput"><span class="identifier">Period2</span><span class="special">::</span><span class="identifier">den</span></code>.
</p>
<p>
- <span class="bold"><strong>Note:</strong></span> The typedef type is the <code class="computeroutput"><span class="identifier">duration</span></code> with the largest tick period
- possible where both <code class="computeroutput"><span class="identifier">duration</span></code>
- arguments will convert to it without requiring a division operation.
- The representation of this type is intended to be able to hold any
- value resulting from this conversion, with the possible exception of
- round-off error when floating point <code class="computeroutput"><span class="identifier">duration</span></code>s
- are involved (but not truncation error).
+ <span class="bold"><strong>Note:</strong></span> The typedef type is the link_text
+ with the largest tick period possible where both link_text arguments
+ will convert to it without requiring a division operation. The representation
+ of this type is intended to be able to hold any value resulting from
+ this conversion, with the possible exception of round-off error when
+ floating point <span class="underline">_duration</span>_s are
+ involved (but not truncation error).
</p>
<pre class="programlisting"><span class="keyword">template</span> <span class="special"><</span><span class="keyword">class</span> <span class="identifier">Clock</span><span class="special">,</span> <span class="keyword">class</span> <span class="identifier">Duration1</span><span class="special">,</span> <span class="keyword">class</span> <span class="identifier">Duration2</span><span class="special">></span>
<span class="keyword">struct</span> <span class="identifier">common_type</span><span class="special"><</span><span class="identifier">chrono</span><span class="special">::</span><span class="identifier">time_point</span><span class="special"><</span><span class="identifier">Clock</span><span class="special">,</span> <span class="identifier">Duration1</span><span class="special">>,</span> <span class="identifier">chrono</span><span class="special">::</span><span class="identifier">time_point</span><span class="special"><</span><span class="identifier">Clock</span><span class="special">,</span> <span class="identifier">Duration2</span><span class="special">></span> <span class="special">></span>
@@ -940,64 +1107,60 @@
<span class="special">};</span>
</pre>
<p>
- The <code class="computeroutput"><span class="identifier">common_type</span></code> of
- two <code class="computeroutput"><span class="identifier">time_point</span></code>s is
- a <code class="computeroutput"><span class="identifier">time_point</span></code> with the
- same <code class="computeroutput"><span class="identifier">clock</span></code> (both have
- the same <code class="computeroutput"><span class="identifier">clock</span></code>), and
- the <code class="computeroutput"><span class="identifier">common_type</span></code> of
- the two <code class="computeroutput"><span class="identifier">duration</span></code>s.
+ The link_text of two __time<span class="underline">point</span>_s
+ is a <code class="computeroutput"><span class="identifier">time_point</span></code> with
+ the same <code class="computeroutput"><span class="identifier">clock</span></code> (both
+ have the same <code class="computeroutput"><span class="identifier">clock</span></code>),
+ and the link_text of the two <span class="underline">_duration</span>_s.
</p>
</div>
</div>
<div class="section" lang="en">
<div class="titlepage"><div><div><h5 class="title">
-<a name="boost_chrono.reference.cpp0x.chrono_chrono_hpp.class_template__duration_"></a><a href="cpp0x.html#boost_chrono.reference.cpp0x.chrono_chrono_hpp.class_template__duration_" title="Class
- template duration">Class
- template <code class="computeroutput"><span class="identifier">duration</span></code></a>
+<a name="boost_chrono.reference.cpp0x.chrono_chrono_hpp.class_template___duration__"></a><a href="cpp0x.html#boost_chrono.reference.cpp0x.chrono_chrono_hpp.class_template___duration__" title="Class
+ template link_text">Class
+ template link_text</a>
</h5></div></div></div>
<div class="toc"><dl>
-<dt><span class="section"><a href="cpp0x.html#boost_chrono.reference.cpp0x.chrono_chrono_hpp.class_template__duration_.duration_c_1">
+<dt><span class="section"><a href="cpp0x.html#boost_chrono.reference.cpp0x.chrono_chrono_hpp.class_template___duration__.duration_c_1">
Constructor <code class="computeroutput"><span class="identifier">duration</span><span class="special">(</span><span class="keyword">const</span> <span class="identifier">Rep2</span><span class="special">&)</span></code></a></span></dt>
-<dt><span class="section"><a href="cpp0x.html#boost_chrono.reference.cpp0x.chrono_chrono_hpp.class_template__duration_.duration_c_2">
+<dt><span class="section"><a href="cpp0x.html#boost_chrono.reference.cpp0x.chrono_chrono_hpp.class_template___duration__.duration_c_2">
Constructor <code class="computeroutput"><span class="identifier">duration</span><span class="special">(</span><span class="keyword">const</span> <span class="identifier">duration</span><span class="special">&)</span></code></a></span></dt>
-<dt><span class="section"><a href="cpp0x.html#boost_chrono.reference.cpp0x.chrono_chrono_hpp.class_template__duration_.count">
+<dt><span class="section"><a href="cpp0x.html#boost_chrono.reference.cpp0x.chrono_chrono_hpp.class_template___duration__.count">
Member function <code class="computeroutput"><span class="identifier">count</span><span class="special">()</span> <span class="keyword">const</span></code></a></span></dt>
-<dt><span class="section"><a href="cpp0x.html#boost_chrono.reference.cpp0x.chrono_chrono_hpp.class_template__duration_.duration_operator_p">
+<dt><span class="section"><a href="cpp0x.html#boost_chrono.reference.cpp0x.chrono_chrono_hpp.class_template___duration__.duration_operator_p">
Member function <code class="computeroutput"><span class="keyword">operator</span><span class="special">+()</span> <span class="keyword">const</span></code></a></span></dt>
-<dt><span class="section"><a href="cpp0x.html#boost_chrono.reference.cpp0x.chrono_chrono_hpp.class_template__duration_.duration_operator_m">
+<dt><span class="section"><a href="cpp0x.html#boost_chrono.reference.cpp0x.chrono_chrono_hpp.class_template___duration__.duration_operator_m">
Member function <code class="computeroutput"><span class="keyword">operator</span><span class="special">+()</span> <span class="keyword">const</span></code></a></span></dt>
-<dt><span class="section"><a href="cpp0x.html#boost_chrono.reference.cpp0x.chrono_chrono_hpp.class_template__duration_.duration_operator_pp">
+<dt><span class="section"><a href="cpp0x.html#boost_chrono.reference.cpp0x.chrono_chrono_hpp.class_template___duration__.duration_operator_pp">
Member function <code class="computeroutput"><span class="keyword">operator</span><span class="special">++()</span></code></a></span></dt>
-<dt><span class="section"><a href="cpp0x.html#boost_chrono.reference.cpp0x.chrono_chrono_hpp.class_template__duration_.duration_operator_pp2">
+<dt><span class="section"><a href="cpp0x.html#boost_chrono.reference.cpp0x.chrono_chrono_hpp.class_template___duration__.duration_operator_pp2">
Member function <code class="computeroutput"><span class="keyword">operator</span><span class="special">++(</span><span class="keyword">int</span><span class="special">)</span></code></a></span></dt>
-<dt><span class="section"><a href="cpp0x.html#boost_chrono.reference.cpp0x.chrono_chrono_hpp.class_template__duration_.duration_operator_mm">
+<dt><span class="section"><a href="cpp0x.html#boost_chrono.reference.cpp0x.chrono_chrono_hpp.class_template___duration__.duration_operator_mm">
Member function <code class="computeroutput"><span class="keyword">operator</span><span class="special">++()</span></code></a></span></dt>
-<dt><span class="section"><a href="cpp0x.html#boost_chrono.reference.cpp0x.chrono_chrono_hpp.class_template__duration_.duration_operator_mm2">
+<dt><span class="section"><a href="cpp0x.html#boost_chrono.reference.cpp0x.chrono_chrono_hpp.class_template___duration__.duration_operator_mm2">
Member function <code class="computeroutput"><span class="keyword">operator</span><span class="special">++(</span><span class="keyword">int</span><span class="special">)</span></code></a></span></dt>
-<dt><span class="section"><a href="cpp0x.html#boost_chrono.reference.cpp0x.chrono_chrono_hpp.class_template__duration_.duration_operator_pa">
+<dt><span class="section"><a href="cpp0x.html#boost_chrono.reference.cpp0x.chrono_chrono_hpp.class_template___duration__.duration_operator_pa">
Member function <code class="computeroutput"><span class="keyword">operator</span><span class="special">+=(</span><span class="keyword">const</span> <span class="identifier">duration</span><span class="special">&)</span></code></a></span></dt>
-<dt><span class="section"><a href="cpp0x.html#boost_chrono.reference.cpp0x.chrono_chrono_hpp.class_template__duration_.duration_operator_ma">
+<dt><span class="section"><a href="cpp0x.html#boost_chrono.reference.cpp0x.chrono_chrono_hpp.class_template___duration__.duration_operator_ma">
Member function <code class="computeroutput"><span class="keyword">operator</span><span class="special">-=(</span><span class="keyword">const</span> <span class="identifier">duration</span><span class="special">&)</span></code></a></span></dt>
-<dt><span class="section"><a href="cpp0x.html#boost_chrono.reference.cpp0x.chrono_chrono_hpp.class_template__duration_.duration_operator_moda">
+<dt><span class="section"><a href="cpp0x.html#boost_chrono.reference.cpp0x.chrono_chrono_hpp.class_template___duration__.duration_operator_moda">
Member function <code class="computeroutput"><span class="keyword">operator</span><span class="special">%=(</span><span class="keyword">const</span> <span class="identifier">duration</span><span class="special">&)</span></code></a></span></dt>
-<dt><span class="section"><a href="cpp0x.html#boost_chrono.reference.cpp0x.chrono_chrono_hpp.class_template__duration_.duration_operator_proda">
+<dt><span class="section"><a href="cpp0x.html#boost_chrono.reference.cpp0x.chrono_chrono_hpp.class_template___duration__.duration_operator_proda">
Member function <code class="computeroutput"><span class="keyword">operator</span><span class="special">*=(</span><span class="keyword">const</span> <span class="identifier">rep</span><span class="special">&)</span></code></a></span></dt>
-<dt><span class="section"><a href="cpp0x.html#boost_chrono.reference.cpp0x.chrono_chrono_hpp.class_template__duration_.duration_operator_da">
+<dt><span class="section"><a href="cpp0x.html#boost_chrono.reference.cpp0x.chrono_chrono_hpp.class_template___duration__.duration_operator_da">
Member function <code class="computeroutput"><span class="keyword">operator</span><span class="special">/=(</span><span class="keyword">const</span> <span class="identifier">rep</span><span class="special">&)</span></code></a></span></dt>
-<dt><span class="section"><a href="cpp0x.html#boost_chrono.reference.cpp0x.chrono_chrono_hpp.class_template__duration_.duration_operator_moda_2">
+<dt><span class="section"><a href="cpp0x.html#boost_chrono.reference.cpp0x.chrono_chrono_hpp.class_template___duration__.duration_operator_moda_2">
Member function <code class="computeroutput"><span class="keyword">operator</span><span class="special">%=(</span><span class="keyword">const</span> <span class="identifier">rep</span><span class="special">&)</span></code></a></span></dt>
-<dt><span class="section"><a href="cpp0x.html#boost_chrono.reference.cpp0x.chrono_chrono_hpp.class_template__duration_.duration_zero">
+<dt><span class="section"><a href="cpp0x.html#boost_chrono.reference.cpp0x.chrono_chrono_hpp.class_template___duration__.duration_zero">
Static Member function <code class="computeroutput"><span class="identifier">zero</span><span class="special">()</span></code></a></span></dt>
-<dt><span class="section"><a href="cpp0x.html#boost_chrono.reference.cpp0x.chrono_chrono_hpp.class_template__duration_.duration_min">
+<dt><span class="section"><a href="cpp0x.html#boost_chrono.reference.cpp0x.chrono_chrono_hpp.class_template___duration__.duration_min">
Static Member function <code class="computeroutput"><span class="identifier">min</span><span class="special">()</span></code></a></span></dt>
-<dt><span class="section"><a href="cpp0x.html#boost_chrono.reference.cpp0x.chrono_chrono_hpp.class_template__duration_.duration_max">
+<dt><span class="section"><a href="cpp0x.html#boost_chrono.reference.cpp0x.chrono_chrono_hpp.class_template___duration__.duration_max">
Static Member function <code class="computeroutput"><span class="identifier">max</span><span class="special">()</span></code></a></span></dt>
</dl></div>
<p>
- A <code class="computeroutput"><span class="identifier">duration</span></code> measures time
- between two points in time (<code class="computeroutput"><span class="identifier">time_point</span></code>).
- A <code class="computeroutput"><span class="identifier">duration</span></code> has a representation
+ A link_text measures time between two points in time ( <code class="computeroutput"><span class="identifier">time_point</span></code>). A link_text has a representation
which holds a count of ticks, and a tick period. The tick period is the
amount of time which occurs from one tick to another in units of a second.
It is expressed as a rational constant using <code class="computeroutput"><span class="identifier">ratio</span></code>.
@@ -1062,10 +1225,9 @@
</pre>
<p>
Rep must be an arithmetic type, or a class emulating an arithmetic type,
- compile diagnostic otherwise. If <code class="computeroutput"><span class="identifier">duration</span></code>
- is instantiated with the type of <code class="computeroutput"><span class="identifier">Rep</span></code>
- being a <code class="computeroutput"><span class="identifier">duration</span></code>, compile
- diagnostic is issued.
+ compile diagnostic otherwise. If link_text is instantiated with the type
+ of <code class="computeroutput"><span class="identifier">Rep</span></code> being a link_text,
+ compile diagnostic is issued.
</p>
<p>
Period must be an instantiation of <code class="computeroutput"><span class="identifier">ratio</span></code>,
@@ -1084,13 +1246,12 @@
<span class="identifier">duration</span><span class="special"><</span><span class="keyword">double</span><span class="special">,</span> <span class="identifier">ratio</span><span class="special"><</span><span class="number">1</span><span class="special">,</span> <span class="number">30</span><span class="special">></span> <span class="special">></span> <span class="identifier">holds</span> <span class="identifier">a</span> <span class="identifier">count</span> <span class="keyword">using</span> <span class="identifier">a</span> <span class="keyword">double</span> <span class="identifier">with</span> <span class="identifier">a</span> <span class="identifier">tick</span> <span class="identifier">period</span> <span class="identifier">of</span> <span class="number">1</span><span class="special">/</span><span class="number">30</span> <span class="identifier">second</span> <span class="special">(</span><span class="identifier">a</span> <span class="identifier">tick</span> <span class="identifier">fre
quency</span> <span class="identifier">of</span> <span class="number">30</span> <span class="identifier">Hz</span><span class="special">).</span>
</pre>
<p>
- The following members of <code class="computeroutput"><span class="identifier">duration</span></code>
- do not throw an exception unless the indicated operations on the representations
- throw an exception.
+ The following members of link_text do not throw an exception unless the
+ indicated operations on the representations throw an exception.
</p>
<div class="section" lang="en">
<div class="titlepage"><div><div><h6 class="title">
-<a name="boost_chrono.reference.cpp0x.chrono_chrono_hpp.class_template__duration_.duration_c_1"></a><a href="cpp0x.html#boost_chrono.reference.cpp0x.chrono_chrono_hpp.class_template__duration_.duration_c_1" title="
+<a name="boost_chrono.reference.cpp0x.chrono_chrono_hpp.class_template___duration__.duration_c_1"></a><a href="cpp0x.html#boost_chrono.reference.cpp0x.chrono_chrono_hpp.class_template___duration__.duration_c_1" title="
Constructor duration(const Rep2&)">
Constructor <code class="computeroutput"><span class="identifier">duration</span><span class="special">(</span><span class="keyword">const</span> <span class="identifier">Rep2</span><span class="special">&)</span></code></a>
</h6></div></div></div>
@@ -1115,9 +1276,9 @@
<p>
If these constraints are not met, this constructor shall not participate
in overload resolution. <span class="bold"><strong>Note:</strong></span> This
- requirement prevents construction of an integral-based <code class="computeroutput"><span class="identifier">duration</span></code> with a floating point representation.
- Such a construction could easily lead to confusion about the value
- of the <code class="computeroutput"><span class="identifier">duration</span></code>.
+ requirement prevents construction of an integral-based link_text with
+ a floating point representation. Such a construction could easily lead
+ to confusion about the value of the link_text.
</p>
<p>
<span class="bold"><strong>Example:</strong></span>
@@ -1127,7 +1288,7 @@
</span></pre>
<p>
<span class="bold"><strong>Effects:</strong></span> Constructs an object of type
- <code class="computeroutput"><span class="identifier">duration</span></code>.
+ link_text.
</p>
<p>
<span class="bold"><strong>PostConditions:</strong></span> <code class="computeroutput"><span class="identifier">count</span><span class="special">()</span> <span class="special">==</span> <span class="keyword">static_cast</span><span class="special"><</span><span class="identifier">rep</span><span class="special">>(</span><span class="identifier">r</span><span class="special">)</span></code>.
@@ -1135,7 +1296,7 @@
</div>
<div class="section" lang="en">
<div class="titlepage"><div><div><h6 class="title">
-<a name="boost_chrono.reference.cpp0x.chrono_chrono_hpp.class_template__duration_.duration_c_2"></a><a href="cpp0x.html#boost_chrono.reference.cpp0x.chrono_chrono_hpp.class_template__duration_.duration_c_2" title="
+<a name="boost_chrono.reference.cpp0x.chrono_chrono_hpp.class_template___duration__.duration_c_2"></a><a href="cpp0x.html#boost_chrono.reference.cpp0x.chrono_chrono_hpp.class_template___duration__.duration_c_2" title="
Constructor duration(const duration&)">
Constructor <code class="computeroutput"><span class="identifier">duration</span><span class="special">(</span><span class="keyword">const</span> <span class="identifier">duration</span><span class="special">&)</span></code></a>
</h6></div></div></div>
@@ -1149,9 +1310,9 @@
<span class="number">1</span></code>, else this constructor shall
not participate in overload resolution. <span class="bold"><strong>note</strong></span>
This requirement prevents implicit truncation error when converting
- between integral-based <code class="computeroutput"><span class="identifier">duration</span></code>s.
+ between integral-based <span class="underline">_duration</span>_s.
Such a construction could easily lead to confusion about the value
- of the <code class="computeroutput"><span class="identifier">duration</span></code>.
+ of the link_text.
</p>
<p>
<span class="bold"><strong>Example:</strong></span>
@@ -1162,13 +1323,13 @@
</span></pre>
<p>
<span class="bold"><strong>Effects:</strong></span> Constructs an object of type
- <code class="computeroutput"><span class="identifier">duration</span></code>, constructing
- <code class="computeroutput"><span class="identifier">rep_</span></code> from <code class="computeroutput"><span class="identifier">duration_cast</span><span class="special"><</span><span class="identifier">duration</span><span class="special">>(</span><span class="identifier">d</span><span class="special">).</span><span class="identifier">count</span><span class="special">()</span></code>.
+ link_text, constructing <code class="computeroutput"><span class="identifier">rep_</span></code>
+ from <code class="computeroutput"><span class="identifier">duration_cast</span><span class="special"><</span><span class="identifier">duration</span><span class="special">>(</span><span class="identifier">d</span><span class="special">).</span><span class="identifier">count</span><span class="special">()</span></code>.
</p>
</div>
<div class="section" lang="en">
<div class="titlepage"><div><div><h6 class="title">
-<a name="boost_chrono.reference.cpp0x.chrono_chrono_hpp.class_template__duration_.count"></a><a href="cpp0x.html#boost_chrono.reference.cpp0x.chrono_chrono_hpp.class_template__duration_.count" title="
+<a name="boost_chrono.reference.cpp0x.chrono_chrono_hpp.class_template___duration__.count"></a><a href="cpp0x.html#boost_chrono.reference.cpp0x.chrono_chrono_hpp.class_template___duration__.count" title="
Member function count() const">
Member function <code class="computeroutput"><span class="identifier">count</span><span class="special">()</span> <span class="keyword">const</span></code></a>
</h6></div></div></div>
@@ -1180,7 +1341,7 @@
</div>
<div class="section" lang="en">
<div class="titlepage"><div><div><h6 class="title">
-<a name="boost_chrono.reference.cpp0x.chrono_chrono_hpp.class_template__duration_.duration_operator_p"></a><a href="cpp0x.html#boost_chrono.reference.cpp0x.chrono_chrono_hpp.class_template__duration_.duration_operator_p" title="
+<a name="boost_chrono.reference.cpp0x.chrono_chrono_hpp.class_template___duration__.duration_operator_p"></a><a href="cpp0x.html#boost_chrono.reference.cpp0x.chrono_chrono_hpp.class_template___duration__.duration_operator_p" title="
Member function operator+() const">
Member function <code class="computeroutput"><span class="keyword">operator</span><span class="special">+()</span> <span class="keyword">const</span></code></a>
</h6></div></div></div>
@@ -1192,7 +1353,7 @@
</div>
<div class="section" lang="en">
<div class="titlepage"><div><div><h6 class="title">
-<a name="boost_chrono.reference.cpp0x.chrono_chrono_hpp.class_template__duration_.duration_operator_m"></a><a href="cpp0x.html#boost_chrono.reference.cpp0x.chrono_chrono_hpp.class_template__duration_.duration_operator_m" title="
+<a name="boost_chrono.reference.cpp0x.chrono_chrono_hpp.class_template___duration__.duration_operator_m"></a><a href="cpp0x.html#boost_chrono.reference.cpp0x.chrono_chrono_hpp.class_template___duration__.duration_operator_m" title="
Member function operator+() const">
Member function <code class="computeroutput"><span class="keyword">operator</span><span class="special">+()</span> <span class="keyword">const</span></code></a>
</h6></div></div></div>
@@ -1204,7 +1365,7 @@
</div>
<div class="section" lang="en">
<div class="titlepage"><div><div><h6 class="title">
-<a name="boost_chrono.reference.cpp0x.chrono_chrono_hpp.class_template__duration_.duration_operator_pp"></a><a href="cpp0x.html#boost_chrono.reference.cpp0x.chrono_chrono_hpp.class_template__duration_.duration_operator_pp" title="
+<a name="boost_chrono.reference.cpp0x.chrono_chrono_hpp.class_template___duration__.duration_operator_pp"></a><a href="cpp0x.html#boost_chrono.reference.cpp0x.chrono_chrono_hpp.class_template___duration__.duration_operator_pp" title="
Member function operator++()">
Member function <code class="computeroutput"><span class="keyword">operator</span><span class="special">++()</span></code></a>
</h6></div></div></div>
@@ -1219,7 +1380,7 @@
</div>
<div class="section" lang="en">
<div class="titlepage"><div><div><h6 class="title">
-<a name="boost_chrono.reference.cpp0x.chrono_chrono_hpp.class_template__duration_.duration_operator_pp2"></a><a href="cpp0x.html#boost_chrono.reference.cpp0x.chrono_chrono_hpp.class_template__duration_.duration_operator_pp2" title="
+<a name="boost_chrono.reference.cpp0x.chrono_chrono_hpp.class_template___duration__.duration_operator_pp2"></a><a href="cpp0x.html#boost_chrono.reference.cpp0x.chrono_chrono_hpp.class_template___duration__.duration_operator_pp2" title="
Member function operator++(int)">
Member function <code class="computeroutput"><span class="keyword">operator</span><span class="special">++(</span><span class="keyword">int</span><span class="special">)</span></code></a>
</h6></div></div></div>
@@ -1231,7 +1392,7 @@
</div>
<div class="section" lang="en">
<div class="titlepage"><div><div><h6 class="title">
-<a name="boost_chrono.reference.cpp0x.chrono_chrono_hpp.class_template__duration_.duration_operator_mm"></a><a href="cpp0x.html#boost_chrono.reference.cpp0x.chrono_chrono_hpp.class_template__duration_.duration_operator_mm" title="
+<a name="boost_chrono.reference.cpp0x.chrono_chrono_hpp.class_template___duration__.duration_operator_mm"></a><a href="cpp0x.html#boost_chrono.reference.cpp0x.chrono_chrono_hpp.class_template___duration__.duration_operator_mm" title="
Member function operator++()">
Member function <code class="computeroutput"><span class="keyword">operator</span><span class="special">++()</span></code></a>
</h6></div></div></div>
@@ -1246,7 +1407,7 @@
</div>
<div class="section" lang="en">
<div class="titlepage"><div><div><h6 class="title">
-<a name="boost_chrono.reference.cpp0x.chrono_chrono_hpp.class_template__duration_.duration_operator_mm2"></a><a href="cpp0x.html#boost_chrono.reference.cpp0x.chrono_chrono_hpp.class_template__duration_.duration_operator_mm2" title="
+<a name="boost_chrono.reference.cpp0x.chrono_chrono_hpp.class_template___duration__.duration_operator_mm2"></a><a href="cpp0x.html#boost_chrono.reference.cpp0x.chrono_chrono_hpp.class_template___duration__.duration_operator_mm2" title="
Member function operator++(int)">
Member function <code class="computeroutput"><span class="keyword">operator</span><span class="special">++(</span><span class="keyword">int</span><span class="special">)</span></code></a>
</h6></div></div></div>
@@ -1258,7 +1419,7 @@
</div>
<div class="section" lang="en">
<div class="titlepage"><div><div><h6 class="title">
-<a name="boost_chrono.reference.cpp0x.chrono_chrono_hpp.class_template__duration_.duration_operator_pa"></a><a href="cpp0x.html#boost_chrono.reference.cpp0x.chrono_chrono_hpp.class_template__duration_.duration_operator_pa" title="
+<a name="boost_chrono.reference.cpp0x.chrono_chrono_hpp.class_template___duration__.duration_operator_pa"></a><a href="cpp0x.html#boost_chrono.reference.cpp0x.chrono_chrono_hpp.class_template___duration__.duration_operator_pa" title="
Member function operator+=(const duration&)">
Member function <code class="computeroutput"><span class="keyword">operator</span><span class="special">+=(</span><span class="keyword">const</span> <span class="identifier">duration</span><span class="special">&)</span></code></a>
</h6></div></div></div>
@@ -1274,7 +1435,7 @@
</div>
<div class="section" lang="en">
<div class="titlepage"><div><div><h6 class="title">
-<a name="boost_chrono.reference.cpp0x.chrono_chrono_hpp.class_template__duration_.duration_operator_ma"></a><a href="cpp0x.html#boost_chrono.reference.cpp0x.chrono_chrono_hpp.class_template__duration_.duration_operator_ma" title="
+<a name="boost_chrono.reference.cpp0x.chrono_chrono_hpp.class_template___duration__.duration_operator_ma"></a><a href="cpp0x.html#boost_chrono.reference.cpp0x.chrono_chrono_hpp.class_template___duration__.duration_operator_ma" title="
Member function operator-=(const duration&)">
Member function <code class="computeroutput"><span class="keyword">operator</span><span class="special">-=(</span><span class="keyword">const</span> <span class="identifier">duration</span><span class="special">&)</span></code></a>
</h6></div></div></div>
@@ -1290,7 +1451,7 @@
</div>
<div class="section" lang="en">
<div class="titlepage"><div><div><h6 class="title">
-<a name="boost_chrono.reference.cpp0x.chrono_chrono_hpp.class_template__duration_.duration_operator_moda"></a><a href="cpp0x.html#boost_chrono.reference.cpp0x.chrono_chrono_hpp.class_template__duration_.duration_operator_moda" title="
+<a name="boost_chrono.reference.cpp0x.chrono_chrono_hpp.class_template___duration__.duration_operator_moda"></a><a href="cpp0x.html#boost_chrono.reference.cpp0x.chrono_chrono_hpp.class_template___duration__.duration_operator_moda" title="
Member function operator%=(const duration&)">
Member function <code class="computeroutput"><span class="keyword">operator</span><span class="special">%=(</span><span class="keyword">const</span> <span class="identifier">duration</span><span class="special">&)</span></code></a>
</h6></div></div></div>
@@ -1306,7 +1467,7 @@
</div>
<div class="section" lang="en">
<div class="titlepage"><div><div><h6 class="title">
-<a name="boost_chrono.reference.cpp0x.chrono_chrono_hpp.class_template__duration_.duration_operator_proda"></a><a href="cpp0x.html#boost_chrono.reference.cpp0x.chrono_chrono_hpp.class_template__duration_.duration_operator_proda" title="
+<a name="boost_chrono.reference.cpp0x.chrono_chrono_hpp.class_template___duration__.duration_operator_proda"></a><a href="cpp0x.html#boost_chrono.reference.cpp0x.chrono_chrono_hpp.class_template___duration__.duration_operator_proda" title="
Member function operator*=(const rep&)">
Member function <code class="computeroutput"><span class="keyword">operator</span><span class="special">*=(</span><span class="keyword">const</span> <span class="identifier">rep</span><span class="special">&)</span></code></a>
</h6></div></div></div>
@@ -1322,7 +1483,7 @@
</div>
<div class="section" lang="en">
<div class="titlepage"><div><div><h6 class="title">
-<a name="boost_chrono.reference.cpp0x.chrono_chrono_hpp.class_template__duration_.duration_operator_da"></a><a href="cpp0x.html#boost_chrono.reference.cpp0x.chrono_chrono_hpp.class_template__duration_.duration_operator_da" title="
+<a name="boost_chrono.reference.cpp0x.chrono_chrono_hpp.class_template___duration__.duration_operator_da"></a><a href="cpp0x.html#boost_chrono.reference.cpp0x.chrono_chrono_hpp.class_template___duration__.duration_operator_da" title="
Member function operator/=(const rep&)">
Member function <code class="computeroutput"><span class="keyword">operator</span><span class="special">/=(</span><span class="keyword">const</span> <span class="identifier">rep</span><span class="special">&)</span></code></a>
</h6></div></div></div>
@@ -1338,7 +1499,7 @@
</div>
<div class="section" lang="en">
<div class="titlepage"><div><div><h6 class="title">
-<a name="boost_chrono.reference.cpp0x.chrono_chrono_hpp.class_template__duration_.duration_operator_moda_2"></a><a href="cpp0x.html#boost_chrono.reference.cpp0x.chrono_chrono_hpp.class_template__duration_.duration_operator_moda_2" title="
+<a name="boost_chrono.reference.cpp0x.chrono_chrono_hpp.class_template___duration__.duration_operator_moda_2"></a><a href="cpp0x.html#boost_chrono.reference.cpp0x.chrono_chrono_hpp.class_template___duration__.duration_operator_moda_2" title="
Member function operator%=(const rep&)">
Member function <code class="computeroutput"><span class="keyword">operator</span><span class="special">%=(</span><span class="keyword">const</span> <span class="identifier">rep</span><span class="special">&)</span></code></a>
</h6></div></div></div>
@@ -1354,7 +1515,7 @@
</div>
<div class="section" lang="en">
<div class="titlepage"><div><div><h6 class="title">
-<a name="boost_chrono.reference.cpp0x.chrono_chrono_hpp.class_template__duration_.duration_zero"></a><a href="cpp0x.html#boost_chrono.reference.cpp0x.chrono_chrono_hpp.class_template__duration_.duration_zero" title="
+<a name="boost_chrono.reference.cpp0x.chrono_chrono_hpp.class_template___duration__.duration_zero"></a><a href="cpp0x.html#boost_chrono.reference.cpp0x.chrono_chrono_hpp.class_template___duration__.duration_zero" title="
Static Member function zero()">
Static Member function <code class="computeroutput"><span class="identifier">zero</span><span class="special">()</span></code></a>
</h6></div></div></div>
@@ -1366,7 +1527,7 @@
</div>
<div class="section" lang="en">
<div class="titlepage"><div><div><h6 class="title">
-<a name="boost_chrono.reference.cpp0x.chrono_chrono_hpp.class_template__duration_.duration_min"></a><a href="cpp0x.html#boost_chrono.reference.cpp0x.chrono_chrono_hpp.class_template__duration_.duration_min" title="
+<a name="boost_chrono.reference.cpp0x.chrono_chrono_hpp.class_template___duration__.duration_min"></a><a href="cpp0x.html#boost_chrono.reference.cpp0x.chrono_chrono_hpp.class_template___duration__.duration_min" title="
Static Member function min()">
Static Member function <code class="computeroutput"><span class="identifier">min</span><span class="special">()</span></code></a>
</h6></div></div></div>
@@ -1378,7 +1539,7 @@
</div>
<div class="section" lang="en">
<div class="titlepage"><div><div><h6 class="title">
-<a name="boost_chrono.reference.cpp0x.chrono_chrono_hpp.class_template__duration_.duration_max"></a><a href="cpp0x.html#boost_chrono.reference.cpp0x.chrono_chrono_hpp.class_template__duration_.duration_max" title="
+<a name="boost_chrono.reference.cpp0x.chrono_chrono_hpp.class_template___duration__.duration_max"></a><a href="cpp0x.html#boost_chrono.reference.cpp0x.chrono_chrono_hpp.class_template___duration__.duration_max" title="
Static Member function max()">
Static Member function <code class="computeroutput"><span class="identifier">max</span><span class="special">()</span></code></a>
</h6></div></div></div>
@@ -1448,11 +1609,10 @@
</pre>
<p>
<span class="bold"><strong>Requires:</strong></span> Let <code class="computeroutput"><span class="identifier">CR</span></code>
- represent the <code class="computeroutput"><span class="identifier">common_type</span></code>
- of <code class="computeroutput"><span class="identifier">Rep1</span></code> and <code class="computeroutput"><span class="identifier">Rep2</span></code>. This function will not participate
- in overload resolution unless both <code class="computeroutput"><span class="identifier">Rep1</span></code>
- and <code class="computeroutput"><span class="identifier">Rep2</span></code> are implicitly
- convertible to <code class="computeroutput"><span class="identifier">CR</span></code>.
+ represent the link_text of <code class="computeroutput"><span class="identifier">Rep1</span></code>
+ and <code class="computeroutput"><span class="identifier">Rep2</span></code>. This function
+ will not participate in overload resolution unless both <code class="computeroutput"><span class="identifier">Rep1</span></code> and <code class="computeroutput"><span class="identifier">Rep2</span></code>
+ are implicitly convertible to <code class="computeroutput"><span class="identifier">CR</span></code>.
</p>
<p>
<span class="bold"><strong>Returns:</strong></span> <code class="computeroutput"><span class="identifier">duration</span><span class="special"><</span><span class="identifier">CR</span><span class="special">,</span> <span class="identifier">Period</span><span class="special">>(</span><span class="identifier">d</span><span class="special">)</span> <span class="special">*=</span> <span class="identifier">s</span></code>.
@@ -1470,11 +1630,10 @@
</pre>
<p>
<span class="bold"><strong>Requires:</strong></span> Let <code class="computeroutput"><span class="identifier">CR</span></code>
- represent the <code class="computeroutput"><span class="identifier">common_type</span></code>
- of <code class="computeroutput"><span class="identifier">Rep1</span></code> and <code class="computeroutput"><span class="identifier">Rep2</span></code>. This function will not participate
- in overload resolution unless both <code class="computeroutput"><span class="identifier">Rep1</span></code>
- and <code class="computeroutput"><span class="identifier">Rep2</span></code> are implicitly
- convertible to <code class="computeroutput"><span class="identifier">CR</span></code>.
+ represent the link_text of <code class="computeroutput"><span class="identifier">Rep1</span></code>
+ and <code class="computeroutput"><span class="identifier">Rep2</span></code>. This function
+ will not participate in overload resolution unless both <code class="computeroutput"><span class="identifier">Rep1</span></code> and <code class="computeroutput"><span class="identifier">Rep2</span></code>
+ are implicitly convertible to <code class="computeroutput"><span class="identifier">CR</span></code>.
</p>
<p>
<span class="bold"><strong>Returns:</strong></span> <code class="computeroutput"><span class="identifier">d</span>
@@ -1493,13 +1652,12 @@
</pre>
<p>
<span class="bold"><strong>Requires:</strong></span> Let <code class="computeroutput"><span class="identifier">CR</span></code>
- represent the <code class="computeroutput"><span class="identifier">common_type</span></code>
- of <code class="computeroutput"><span class="identifier">Rep1</span></code> and <code class="computeroutput"><span class="identifier">Rep2</span></code>. This function will not participate
- in overload resolution unless both <code class="computeroutput"><span class="identifier">Rep1</span></code>
- and <code class="computeroutput"><span class="identifier">Rep2</span></code> are implicitly
- convertible to <code class="computeroutput"><span class="identifier">CR</span></code>,
+ represent the link_text of <code class="computeroutput"><span class="identifier">Rep1</span></code>
+ and <code class="computeroutput"><span class="identifier">Rep2</span></code>. This function
+ will not participate in overload resolution unless both <code class="computeroutput"><span class="identifier">Rep1</span></code> and <code class="computeroutput"><span class="identifier">Rep2</span></code>
+ are implicitly convertible to <code class="computeroutput"><span class="identifier">CR</span></code>,
and <code class="computeroutput"><span class="identifier">Rep2</span></code> is not an
- instantiation of <code class="computeroutput"><span class="identifier">duration</span></code>.
+ instantiation of link_text.
</p>
<p>
<span class="bold"><strong>Returns:</strong></span> <code class="computeroutput"><span class="identifier">duration</span><span class="special"><</span><span class="identifier">CR</span><span class="special">,</span> <span class="identifier">Period</span><span class="special">>(</span><span class="identifier">d</span><span class="special">)</span> <span class="special">/=</span> <span class="identifier">s</span></code>.
@@ -1517,9 +1675,8 @@
</pre>
<p>
<span class="bold"><strong>Returns:</strong></span> Let <code class="computeroutput"><span class="identifier">CD</span></code>
- represent the <code class="computeroutput"><span class="identifier">common_type</span></code>
- of the two <code class="computeroutput"><span class="identifier">duration</span></code>
- arguments. Returns <code class="computeroutput"><span class="identifier">CD</span><span class="special">(</span><span class="identifier">lhs</span><span class="special">).</span><span class="identifier">count</span><span class="special">()</span> <span class="special">/</span> <span class="identifier">CD</span><span class="special">(</span><span class="identifier">rhs</span><span class="special">).</span><span class="identifier">count</span><span class="special">()</span></code>.
+ represent the link_text of the two link_text arguments. Returns <code class="computeroutput"><span class="identifier">CD</span><span class="special">(</span><span class="identifier">lhs</span><span class="special">).</span><span class="identifier">count</span><span class="special">()</span>
+ <span class="special">/</span> <span class="identifier">CD</span><span class="special">(</span><span class="identifier">rhs</span><span class="special">).</span><span class="identifier">count</span><span class="special">()</span></code>.
</p>
</div>
<div class="section" lang="en">
@@ -1533,13 +1690,12 @@
</pre>
<p>
<span class="bold"><strong>Remarks:</strong></span> Let <code class="computeroutput"><span class="identifier">CR</span></code>
- represent the <code class="computeroutput"><span class="identifier">common_type</span></code>
- of <code class="computeroutput"><span class="identifier">Rep1</span></code> and <code class="computeroutput"><span class="identifier">Rep2</span></code>. This function will not participate
- in overload resolution unless both <code class="computeroutput"><span class="identifier">Rep1</span></code>
- and <code class="computeroutput"><span class="identifier">Rep2</span></code> are implicitly
- convertible to <code class="computeroutput"><span class="identifier">CR</span></code>,
+ represent the link_text of <code class="computeroutput"><span class="identifier">Rep1</span></code>
+ and <code class="computeroutput"><span class="identifier">Rep2</span></code>. This function
+ will not participate in overload resolution unless both <code class="computeroutput"><span class="identifier">Rep1</span></code> and <code class="computeroutput"><span class="identifier">Rep2</span></code>
+ are implicitly convertible to <code class="computeroutput"><span class="identifier">CR</span></code>,
and <code class="computeroutput"><span class="identifier">Rep1</span></code> is not an
- instantiation of <code class="computeroutput"><span class="identifier">duration</span></code>.
+ instantiation of link_text.
</p>
<p>
<span class="bold"><strong>Returns:</strong></span> <code class="computeroutput"><span class="identifier">CR</span><span class="special">(</span><span class="identifier">s</span><span class="special">)/</span><span class="identifier">duration</span><span class="special"><</span><span class="identifier">CR</span><span class="special">,</span> <span class="identifier">Period</span><span class="special">>(</span><span class="identifier">d</span><span class="special">)</span></code>.
@@ -1615,9 +1771,8 @@
</pre>
<p>
<span class="bold"><strong>Returns:</strong></span> Let <code class="computeroutput"><span class="identifier">CD</span></code>
- represent the <code class="computeroutput"><span class="identifier">common_type</span></code>
- of the two <code class="computeroutput"><span class="identifier">duration</span></code>
- arguments. Returns <code class="computeroutput"><span class="identifier">CD</span><span class="special">(</span><span class="identifier">lhs</span><span class="special">).</span><span class="identifier">count</span><span class="special">()</span> <span class="special">==</span> <span class="identifier">CD</span><span class="special">(</span><span class="identifier">rhs</span><span class="special">).</span><span class="identifier">count</span><span class="special">()</span></code>
+ represent the link_text of the two link_text arguments. Returns <code class="computeroutput"><span class="identifier">CD</span><span class="special">(</span><span class="identifier">lhs</span><span class="special">).</span><span class="identifier">count</span><span class="special">()</span>
+ <span class="special">==</span> <span class="identifier">CD</span><span class="special">(</span><span class="identifier">rhs</span><span class="special">).</span><span class="identifier">count</span><span class="special">()</span></code>
</p>
</div>
<div class="section" lang="en">
@@ -1645,9 +1800,8 @@
</pre>
<p>
<span class="bold"><strong>Returns:</strong></span> Let <code class="computeroutput"><span class="identifier">CD</span></code>
- represent the <code class="computeroutput"><span class="identifier">common_type</span></code>
- of the two <code class="computeroutput"><span class="identifier">duration</span></code>
- arguments. Returns <code class="computeroutput"><span class="identifier">CD</span><span class="special">(</span><span class="identifier">lhs</span><span class="special">).</span><span class="identifier">count</span><span class="special">()</span> <span class="special"><</span> <span class="identifier">CD</span><span class="special">(</span><span class="identifier">rhs</span><span class="special">).</span><span class="identifier">count</span><span class="special">()</span></code>
+ represent the link_text of the two link_text arguments. Returns <code class="computeroutput"><span class="identifier">CD</span><span class="special">(</span><span class="identifier">lhs</span><span class="special">).</span><span class="identifier">count</span><span class="special">()</span>
+ <span class="special"><</span> <span class="identifier">CD</span><span class="special">(</span><span class="identifier">rhs</span><span class="special">).</span><span class="identifier">count</span><span class="special">()</span></code>
</p>
</div>
<div class="section" lang="en">
@@ -1705,14 +1859,15 @@
<p>
<span class="bold"><strong>Requires:</strong></span> This function will not participate
in overload resolution unless <code class="computeroutput"><span class="identifier">ToDuration</span></code>
- is an instantiation of <code class="computeroutput"><span class="identifier">duration</span></code>.
+ is an instantiation of link_text.
</p>
<p>
<span class="bold"><strong>Returns:</strong></span> Forms <code class="computeroutput"><span class="identifier">CF</span></code>
which is a <code class="computeroutput"><span class="identifier">ratio</span></code> resulting
from <code class="computeroutput"><span class="identifier">ratio_divide</span><span class="special"><</span><span class="identifier">Period</span><span class="special">,</span> <span class="keyword">typename</span> <span class="identifier">ToDuration</span><span class="special">::</span><span class="identifier">period</span><span class="special">>::</span><span class="identifier">type</span></code>.
- Let <code class="computeroutput"><span class="identifier">CR</span></code> be the <code class="computeroutput"><span class="identifier">common_type</span></code> of <code class="computeroutput"><span class="identifier">ToDuration</span><span class="special">::</span><span class="identifier">rep</span></code>,
- <code class="computeroutput"><span class="identifier">Rep</span></code>, and <code class="computeroutput"><span class="identifier">intmax_t</span></code>.
+ Let <code class="computeroutput"><span class="identifier">CR</span></code> be the link_text
+ of <code class="computeroutput"><span class="identifier">ToDuration</span><span class="special">::</span><span class="identifier">rep</span></code>, <code class="computeroutput"><span class="identifier">Rep</span></code>,
+ and <code class="computeroutput"><span class="identifier">intmax_t</span></code>.
</p>
<div class="itemizedlist"><ul type="disc">
<li>
@@ -1754,26 +1909,26 @@
</div>
<div class="section" lang="en">
<div class="titlepage"><div><div><h5 class="title">
-<a name="boost_chrono.reference.cpp0x.chrono_chrono_hpp.class_template__time_point_"></a><a href="cpp0x.html#boost_chrono.reference.cpp0x.chrono_chrono_hpp.class_template__time_point_" title="Class
+<a name="boost_chrono.reference.cpp0x.chrono_chrono_hpp.class_template___time_point__"></a><a href="cpp0x.html#boost_chrono.reference.cpp0x.chrono_chrono_hpp.class_template___time_point__" title="Class
template time_point">Class
template <code class="computeroutput"><span class="identifier">time_point</span></code></a>
</h5></div></div></div>
<div class="toc"><dl>
-<dt><span class="section"><a href="cpp0x.html#boost_chrono.reference.cpp0x.chrono_chrono_hpp.class_template__time_point_.time_point_c_1">
+<dt><span class="section"><a href="cpp0x.html#boost_chrono.reference.cpp0x.chrono_chrono_hpp.class_template___time_point__.time_point_c_1">
Constructor <code class="computeroutput"><span class="identifier">time_point</span><span class="special">()</span></code></a></span></dt>
-<dt><span class="section"><a href="cpp0x.html#boost_chrono.reference.cpp0x.chrono_chrono_hpp.class_template__time_point_.time_point_c_2">
+<dt><span class="section"><a href="cpp0x.html#boost_chrono.reference.cpp0x.chrono_chrono_hpp.class_template___time_point__.time_point_c_2">
Constructor <code class="computeroutput"><span class="identifier">time_point</span><span class="special">(</span><span class="keyword">const</span> <span class="identifier">duration</span><span class="special">&)</span></code></a></span></dt>
-<dt><span class="section"><a href="cpp0x.html#boost_chrono.reference.cpp0x.chrono_chrono_hpp.class_template__time_point_.time_point_c_3">
+<dt><span class="section"><a href="cpp0x.html#boost_chrono.reference.cpp0x.chrono_chrono_hpp.class_template___time_point__.time_point_c_3">
Constructor <code class="computeroutput"><span class="identifier">time_point</span><span class="special">(</span><span class="keyword">const</span> <span class="identifier">duration</span><span class="special">&)</span></code></a></span></dt>
-<dt><span class="section"><a href="cpp0x.html#boost_chrono.reference.cpp0x.chrono_chrono_hpp.class_template__time_point_.time_since_epoch">
+<dt><span class="section"><a href="cpp0x.html#boost_chrono.reference.cpp0x.chrono_chrono_hpp.class_template___time_point__.time_since_epoch">
Member function <code class="computeroutput"><span class="identifier">time_since_epoch</span><span class="special">()</span> <span class="keyword">const</span></code></a></span></dt>
-<dt><span class="section"><a href="cpp0x.html#boost_chrono.reference.cpp0x.chrono_chrono_hpp.class_template__time_point_.time_point_operator_pe">
+<dt><span class="section"><a href="cpp0x.html#boost_chrono.reference.cpp0x.chrono_chrono_hpp.class_template___time_point__.time_point_operator_pe">
Member function <code class="computeroutput"><span class="keyword">operator</span><span class="special">+=</span></code></a></span></dt>
-<dt><span class="section"><a href="cpp0x.html#boost_chrono.reference.cpp0x.chrono_chrono_hpp.class_template__time_point_.time_point_operator_me">
+<dt><span class="section"><a href="cpp0x.html#boost_chrono.reference.cpp0x.chrono_chrono_hpp.class_template___time_point__.time_point_operator_me">
Member function <code class="computeroutput"><span class="keyword">operator</span><span class="special">-=</span></code></a></span></dt>
-<dt><span class="section"><a href="cpp0x.html#boost_chrono.reference.cpp0x.chrono_chrono_hpp.class_template__time_point_.time_point_min">
+<dt><span class="section"><a href="cpp0x.html#boost_chrono.reference.cpp0x.chrono_chrono_hpp.class_template___time_point__.time_point_min">
Static Member function <code class="computeroutput"><span class="identifier">min</span></code></a></span></dt>
-<dt><span class="section"><a href="cpp0x.html#boost_chrono.reference.cpp0x.chrono_chrono_hpp.class_template__time_point_.time_point_max">
+<dt><span class="section"><a href="cpp0x.html#boost_chrono.reference.cpp0x.chrono_chrono_hpp.class_template___time_point__.time_point_max">
Static Member function <code class="computeroutput"><span class="identifier">max</span></code></a></span></dt>
</dl></div>
<p>
@@ -1817,16 +1972,15 @@
<span class="special">};</span>
</pre>
<p>
- Clock must meet the <a href="cpp0x.html#boost_chrono.reference.cpp0x.chrono_chrono_hpp.class__system_clock_" target="_top">Clock
- Requirements</a>.
+ Clock must meet the <a href="cpp0x.html#boost_chrono.reference.cpp0x.chrono_chrono_hpp.clock" title="
+ Clock Requirements"><code class="computeroutput"><span class="identifier">Clock</span></code> requirements</a>.
</p>
<p>
- Duration must be an instantiation of <code class="computeroutput"><span class="identifier">duration</span></code>,
- compile diagnostic otherwise.
+ Duration must be an instantiation of link_text, compile diagnostic otherwise.
</p>
<div class="section" lang="en">
<div class="titlepage"><div><div><h6 class="title">
-<a name="boost_chrono.reference.cpp0x.chrono_chrono_hpp.class_template__time_point_.time_point_c_1"></a><a href="cpp0x.html#boost_chrono.reference.cpp0x.chrono_chrono_hpp.class_template__time_point_.time_point_c_1" title="
+<a name="boost_chrono.reference.cpp0x.chrono_chrono_hpp.class_template___time_point__.time_point_c_1"></a><a href="cpp0x.html#boost_chrono.reference.cpp0x.chrono_chrono_hpp.class_template___time_point__.time_point_c_1" title="
Constructor time_point()">
Constructor <code class="computeroutput"><span class="identifier">time_point</span><span class="special">()</span></code></a>
</h6></div></div></div>
@@ -1842,7 +1996,7 @@
</div>
<div class="section" lang="en">
<div class="titlepage"><div><div><h6 class="title">
-<a name="boost_chrono.reference.cpp0x.chrono_chrono_hpp.class_template__time_point_.time_point_c_2"></a><a href="cpp0x.html#boost_chrono.reference.cpp0x.chrono_chrono_hpp.class_template__time_point_.time_point_c_2" title="
+<a name="boost_chrono.reference.cpp0x.chrono_chrono_hpp.class_template___time_point__.time_point_c_2"></a><a href="cpp0x.html#boost_chrono.reference.cpp0x.chrono_chrono_hpp.class_template___time_point__.time_point_c_2" title="
Constructor time_point(const duration&)">
Constructor <code class="computeroutput"><span class="identifier">time_point</span><span class="special">(</span><span class="keyword">const</span> <span class="identifier">duration</span><span class="special">&)</span></code></a>
</h6></div></div></div>
@@ -1857,7 +2011,7 @@
</div>
<div class="section" lang="en">
<div class="titlepage"><div><div><h6 class="title">
-<a name="boost_chrono.reference.cpp0x.chrono_chrono_hpp.class_template__time_point_.time_point_c_3"></a><a href="cpp0x.html#boost_chrono.reference.cpp0x.chrono_chrono_hpp.class_template__time_point_.time_point_c_3" title="
+<a name="boost_chrono.reference.cpp0x.chrono_chrono_hpp.class_template___time_point__.time_point_c_3"></a><a href="cpp0x.html#boost_chrono.reference.cpp0x.chrono_chrono_hpp.class_template___time_point__.time_point_c_3" title="
Constructor time_point(const duration&)">
Constructor <code class="computeroutput"><span class="identifier">time_point</span><span class="special">(</span><span class="keyword">const</span> <span class="identifier">duration</span><span class="special">&)</span></code></a>
</h6></div></div></div>
@@ -1866,7 +2020,7 @@
<p>
<span class="bold"><strong>Requires:</strong></span> This function will not participate
in overload resolution unless <code class="computeroutput"><span class="identifier">Duration2</span></code>
- is implicitly convertible to <code class="computeroutput"><span class="identifier">duration</span></code>.
+ is implicitly convertible to link_text.
</p>
<p>
<span class="bold"><strong>Effects:</strong></span> Constructs an object of
@@ -1876,7 +2030,7 @@
</div>
<div class="section" lang="en">
<div class="titlepage"><div><div><h6 class="title">
-<a name="boost_chrono.reference.cpp0x.chrono_chrono_hpp.class_template__time_point_.time_since_epoch"></a><a href="cpp0x.html#boost_chrono.reference.cpp0x.chrono_chrono_hpp.class_template__time_point_.time_since_epoch" title="
+<a name="boost_chrono.reference.cpp0x.chrono_chrono_hpp.class_template___time_point__.time_since_epoch"></a><a href="cpp0x.html#boost_chrono.reference.cpp0x.chrono_chrono_hpp.class_template___time_point__.time_since_epoch" title="
Member function time_since_epoch() const">
Member function <code class="computeroutput"><span class="identifier">time_since_epoch</span><span class="special">()</span> <span class="keyword">const</span></code></a>
</h6></div></div></div>
@@ -1888,7 +2042,7 @@
</div>
<div class="section" lang="en">
<div class="titlepage"><div><div><h6 class="title">
-<a name="boost_chrono.reference.cpp0x.chrono_chrono_hpp.class_template__time_point_.time_point_operator_pe"></a><a href="cpp0x.html#boost_chrono.reference.cpp0x.chrono_chrono_hpp.class_template__time_point_.time_point_operator_pe" title="
+<a name="boost_chrono.reference.cpp0x.chrono_chrono_hpp.class_template___time_point__.time_point_operator_pe"></a><a href="cpp0x.html#boost_chrono.reference.cpp0x.chrono_chrono_hpp.class_template___time_point__.time_point_operator_pe" title="
Member function operator+=">
Member function <code class="computeroutput"><span class="keyword">operator</span><span class="special">+=</span></code></a>
</h6></div></div></div>
@@ -1904,7 +2058,7 @@
</div>
<div class="section" lang="en">
<div class="titlepage"><div><div><h6 class="title">
-<a name="boost_chrono.reference.cpp0x.chrono_chrono_hpp.class_template__time_point_.time_point_operator_me"></a><a href="cpp0x.html#boost_chrono.reference.cpp0x.chrono_chrono_hpp.class_template__time_point_.time_point_operator_me" title="
+<a name="boost_chrono.reference.cpp0x.chrono_chrono_hpp.class_template___time_point__.time_point_operator_me"></a><a href="cpp0x.html#boost_chrono.reference.cpp0x.chrono_chrono_hpp.class_template___time_point__.time_point_operator_me" title="
Member function operator-=">
Member function <code class="computeroutput"><span class="keyword">operator</span><span class="special">-=</span></code></a>
</h6></div></div></div>
@@ -1920,7 +2074,7 @@
</div>
<div class="section" lang="en">
<div class="titlepage"><div><div><h6 class="title">
-<a name="boost_chrono.reference.cpp0x.chrono_chrono_hpp.class_template__time_point_.time_point_min"></a><a href="cpp0x.html#boost_chrono.reference.cpp0x.chrono_chrono_hpp.class_template__time_point_.time_point_min" title="
+<a name="boost_chrono.reference.cpp0x.chrono_chrono_hpp.class_template___time_point__.time_point_min"></a><a href="cpp0x.html#boost_chrono.reference.cpp0x.chrono_chrono_hpp.class_template___time_point__.time_point_min" title="
Static Member function min">
Static Member function <code class="computeroutput"><span class="identifier">min</span></code></a>
</h6></div></div></div>
@@ -1932,7 +2086,7 @@
</div>
<div class="section" lang="en">
<div class="titlepage"><div><div><h6 class="title">
-<a name="boost_chrono.reference.cpp0x.chrono_chrono_hpp.class_template__time_point_.time_point_max"></a><a href="cpp0x.html#boost_chrono.reference.cpp0x.chrono_chrono_hpp.class_template__time_point_.time_point_max" title="
+<a name="boost_chrono.reference.cpp0x.chrono_chrono_hpp.class_template___time_point__.time_point_max"></a><a href="cpp0x.html#boost_chrono.reference.cpp0x.chrono_chrono_hpp.class_template___time_point__.time_point_max" title="
Static Member function max">
Static Member function <code class="computeroutput"><span class="identifier">max</span></code></a>
</h6></div></div></div>
@@ -2140,7 +2294,7 @@
<p>
<span class="bold"><strong>Requires:</strong></span> This function will not participate
in overload resolution unless <code class="computeroutput"><span class="identifier">ToDuration</span></code>
- is an instantiation of <code class="computeroutput"><span class="identifier">duration</span></code>.
+ is an instantiation of link_text.
</p>
<p>
<span class="bold"><strong>Returns:</strong></span> <code class="computeroutput"><span class="identifier">time_point</span><span class="special"><</span><span class="identifier">Clock</span><span class="special">,</span> <span class="identifier">ToDuration</span><span class="special">>(</span><span class="identifier">duration_cast</span><span class="special"><</span><span class="identifier">ToDuration</span><span class="special">>(</span><span class="identifier">t</span><span class="special">.</span><span class="identifier">time_since_epoch</span><span class="special">()))</span></code>.
@@ -2186,8 +2340,8 @@
</pre>
<p>
<code class="computeroutput"><span class="identifier">system_clock</span></code> satisfy
- the <a href="cpp0x.html#boost_chrono.reference.cpp0x.chrono_chrono_hpp.class__system_clock_" target="_top">Clock
- Requirements</a>. In addition:
+ the <a href="cpp0x.html#boost_chrono.reference.cpp0x.chrono_chrono_hpp.clock" title="
+ Clock Requirements"><code class="computeroutput"><span class="identifier">Clock</span></code> requirements</a>:
</p>
<div class="itemizedlist"><ul type="disc"><li>
<code class="computeroutput"><span class="identifier">system_clock</span><span class="special">::</span><span class="identifier">duration</span><span class="special">::</span><span class="identifier">min</span><span class="special">()</span> <span class="special"><</span> <span class="identifier">system_clock</span><span class="special">::</span><span class="identifier">duration</span><span class="special">::</span><span class="identifier">zero</span><span class="special">()</span></code> is <code class="computeroutput"><span class="keyword">true</span></code>.
@@ -2244,8 +2398,8 @@
</h5></div></div></div>
<p>
<code class="computeroutput"><span class="identifier">monotonic_clock</span></code> satisfy
- the <a href="cpp0x.html#boost_chrono.reference.cpp0x.chrono_chrono_hpp.class__system_clock_" target="_top">Clock
- Requirements</a>.
+ the <a href="cpp0x.html#boost_chrono.reference.cpp0x.chrono_chrono_hpp.clock" title="
+ Clock Requirements"><code class="computeroutput"><span class="identifier">Clock</span></code> requirements</a>.
</p>
<p>
<code class="computeroutput"><span class="identifier">monotonic_clock</span></code> class
@@ -2276,8 +2430,8 @@
</h5></div></div></div>
<p>
<code class="computeroutput"><span class="identifier">high_resolution_clock</span></code>
- satisfy the <a href="cpp0x.html#boost_chrono.reference.cpp0x.chrono_chrono_hpp.class__system_clock_" target="_top">Clock
- Requirements</a>.
+ satisfy the <a href="cpp0x.html#boost_chrono.reference.cpp0x.chrono_chrono_hpp.clock" title="
+ Clock Requirements"><code class="computeroutput"><span class="identifier">Clock</span></code> requirements</a>.
</p>
<pre class="programlisting"><span class="preprocessor">#ifdef</span> <span class="identifier">BOOST_CHRONO_HAS_CLOCK_MONOTONIC</span>
<span class="keyword">typedef</span> <span class="identifier">monotonic_clock</span> <span class="identifier">high_resolution_clock</span><span class="special">;</span> <span class="comment">// as permitted by [time.clock.hires]
Modified: sandbox/chrono/libs/chrono/doc/html/boost_chrono/reference/other_clocks.html
==============================================================================
--- sandbox/chrono/libs/chrono/doc/html/boost_chrono/reference/other_clocks.html (original)
+++ sandbox/chrono/libs/chrono/doc/html/boost_chrono/reference/other_clocks.html 2010-06-26 11:18:46 EDT (Sat, 26 Jun 2010)
@@ -112,8 +112,8 @@
</h5></div></div></div>
<p>
<code class="computeroutput"><span class="identifier">process_real_cpu_clock</span></code>
- satisfy the <a href="cpp0x.html#boost_chrono.reference.cpp0x.chrono_chrono_hpp.class__system_clock_" target="_top">Clock
- Requirements</a>.
+ satisfy the <a href="cpp0x.html#boost_chrono.reference.cpp0x.chrono_chrono_hpp.clock" title="
+ Clock Requirements"><code class="computeroutput"><span class="identifier">Clock</span></code> requirements</a>.
</p>
<p>
<code class="computeroutput"><span class="identifier">process_real_cpu_clock</span></code>
@@ -141,8 +141,8 @@
</h5></div></div></div>
<p>
<code class="computeroutput"><span class="identifier">process_user_cpu_clock</span></code>
- satisfy the <a href="cpp0x.html#boost_chrono.reference.cpp0x.chrono_chrono_hpp.class__system_clock_" target="_top">Clock
- Requirements</a>.
+ satisfy the <a href="cpp0x.html#boost_chrono.reference.cpp0x.chrono_chrono_hpp.clock" title="
+ Clock Requirements"><code class="computeroutput"><span class="identifier">Clock</span></code> requirements</a>.
</p>
<p>
<code class="computeroutput"><span class="identifier">process_user_cpu_clock</span></code>
@@ -170,8 +170,8 @@
</h5></div></div></div>
<p>
<code class="computeroutput"><span class="identifier">process_system_cpu_clock</span></code>
- satisfy the <a href="cpp0x.html#boost_chrono.reference.cpp0x.chrono_chrono_hpp.class__system_clock_" target="_top">Clock
- Requirements</a>.
+ satisfy the <a href="cpp0x.html#boost_chrono.reference.cpp0x.chrono_chrono_hpp.clock" title="
+ Clock Requirements"><code class="computeroutput"><span class="identifier">Clock</span></code> requirements</a>.
</p>
<p>
<code class="computeroutput"><span class="identifier">process_system_cpu_clock</span></code>
@@ -345,8 +345,8 @@
</h5></div></div></div>
<p>
<code class="computeroutput"><span class="identifier">thread_clock</span></code> satisfy
- the <a href="cpp0x.html#boost_chrono.reference.cpp0x.chrono_chrono_hpp.class__system_clock_" target="_top">Clock
- Requirements</a>.
+ the <a href="cpp0x.html#boost_chrono.reference.cpp0x.chrono_chrono_hpp.clock" title="
+ Clock Requirements"><code class="computeroutput"><span class="identifier">Clock</span></code> requirements</a>.
</p>
<p>
<code class="computeroutput"><span class="identifier">thread_clock</span></code> class provides
@@ -394,7 +394,7 @@
<code class="computeroutput"><span class="identifier">clock</span></code> types.
</p>
<div class="table">
-<a name="id4889842"></a><p class="title"><b>Table 2. SuspendibleClock Requirements</b></p>
+<a name="id4889721"></a><p class="title"><b>Table 2. SuspendibleClock Requirements</b></p>
<table class="table" summary="SuspendibleClock Requirements">
<colgroup>
<col>
@@ -461,7 +461,7 @@
</td>
<td>
<p>
- <code class="computeroutput"><span class="identifier">duration</span></code>
+ link_text
</p>
</td>
<td>
Modified: sandbox/chrono/libs/chrono/doc/html/boost_chrono/reference/stopwatch_reporters.html
==============================================================================
--- sandbox/chrono/libs/chrono/doc/html/boost_chrono/reference/stopwatch_reporters.html (original)
+++ sandbox/chrono/libs/chrono/doc/html/boost_chrono/reference/stopwatch_reporters.html 2010-06-26 11:18:46 EDT (Sat, 26 Jun 2010)
@@ -94,7 +94,7 @@
<code class="computeroutput"><span class="identifier">std</span><span class="special">::</span><span class="identifier">ostream</span></code>, ec is a system::error_code
</p>
<div class="table">
-<a name="id4902237"></a><p class="title"><b>Table 4. Stopwatch Requirements</b></p>
+<a name="id4902104"></a><p class="title"><b>Table 4. Stopwatch Requirements</b></p>
<table class="table" summary="Stopwatch Requirements">
<colgroup>
<col>
Modified: sandbox/chrono/libs/chrono/doc/html/boost_chrono/reference/stopwatches.html
==============================================================================
--- sandbox/chrono/libs/chrono/doc/html/boost_chrono/reference/stopwatches.html (original)
+++ sandbox/chrono/libs/chrono/doc/html/boost_chrono/reference/stopwatches.html 2010-06-26 11:18:46 EDT (Sat, 26 Jun 2010)
@@ -138,7 +138,7 @@
is an instance of <code class="computeroutput"><span class="identifier">S</span></code>.
</p>
<div class="table">
-<a name="id4893436"></a><p class="title"><b>Table 3. Stopwatch Requirements</b></p>
+<a name="id4893308"></a><p class="title"><b>Table 3. Stopwatch Requirements</b></p>
<table class="table" summary="Stopwatch Requirements">
<colgroup>
<col>
@@ -193,8 +193,7 @@
</td>
<td>
<p>
- The <code class="computeroutput"><span class="identifier">duration</span></code>
- type of the <code class="computeroutput"><span class="identifier">clock</span></code>.
+ The link_text type of the <code class="computeroutput"><span class="identifier">clock</span></code>.
</p>
</td>
</tr>
@@ -468,7 +467,8 @@
Member Function <code class="computeroutput"><span class="identifier">elapsed</span><span class="special">()</span></code></a></span></dt></dl></div>
<p>
<code class="computeroutput"><span class="identifier">stopwatch</span><span class="special"><></span></code>
- is a model of a Stopwatch
.
+ is a model of a <a href="stopwatches.html#boost_chrono.reference.stopwatches.stopwatch_req" title="
+ Stopwatch Requirements"><code class="computeroutput"><span class="identifier">Stopwatch</span></code> concept</a>.
</p>
<p>
Knowing how long a part of a program takes to execute is useful in both
@@ -610,9 +610,10 @@
Member Function <code class="computeroutput"><span class="identifier">accumulated</span><span class="special">()</span></code></a></span></dt>
</dl></div>
<p>
- A <code class="computeroutput"><span class="identifier">stopwatch_accumulator</span><span class="special"><></span></code> is a model of a Stopwatch
that allows to accumulate
- the time in several times instead of at once as it is the case of the
- class <code class="computeroutput"><span class="identifier">stopwatch</span><span class="special"><></span></code>.
+ A <code class="computeroutput"><span class="identifier">stopwatch_accumulator</span><span class="special"><></span></code> is a model of a <a href="stopwatches.html#boost_chrono.reference.stopwatches.stopwatch_req" title="
+ Stopwatch Requirements"><code class="computeroutput"><span class="identifier">Stopwatch</span></code> concept</a> that allows
+ to accumulate the time in several times instead of at once as it is the
+ case of the class <code class="computeroutput"><span class="identifier">stopwatch</span><span class="special"><></span></code>.
</p>
<pre class="programlisting"><span class="keyword">template</span> <span class="special"><</span><span class="keyword">class</span> <span class="identifier">Clock</span><span class="special">></span> <span class="keyword">class</span> <span class="identifier">stopwatch_accumulator</span> <span class="special">{</span>
<span class="keyword">public</span><span class="special">:</span>
Modified: sandbox/chrono/libs/chrono/doc/html/boost_chrono/users_guide/ext_references.html
==============================================================================
--- sandbox/chrono/libs/chrono/doc/html/boost_chrono/users_guide/ext_references.html (original)
+++ sandbox/chrono/libs/chrono/doc/html/boost_chrono/users_guide/ext_references.html 2010-06-26 11:18:46 EDT (Sat, 26 Jun 2010)
@@ -52,6 +52,11 @@
<dd><p>
From Vicente Juan Botet Escriba.
</p></dd>
+<dt><span class="term"><a href="http://www.digitalmars.com/d/2.0/phobos/std_traits.html#CommonType" target="_top">D
+ programming language - CommonType trait</a></span></dt>
+<dd><p>
+ From Andrei Alexandrescu.
+ </p></dd>
</dl>
</div>
</div>
Modified: sandbox/chrono/libs/chrono/doc/html/boost_chrono/users_guide/getting_started.html
==============================================================================
--- sandbox/chrono/libs/chrono/doc/html/boost_chrono/users_guide/getting_started.html (original)
+++ sandbox/chrono/libs/chrono/doc/html/boost_chrono/users_guide/getting_started.html 2010-06-26 11:18:46 EDT (Sat, 26 Jun 2010)
@@ -39,7 +39,7 @@
Installing Chrono</a>
</h4></div></div></div>
<a name="boost_chrono.users_guide.getting_started.install.getting__emphasis_role__bold__boost_chrono__emphasis__"></a><h5>
-<a name="id4818252"></a>
+<a name="id4817928"></a>
<a href="getting_started.html#boost_chrono.users_guide.getting_started.install.getting__emphasis_role__bold__boost_chrono__emphasis__">Getting
<span class="bold"><strong>Boost.Chrono</strong></span> </a>
</h5>
@@ -54,7 +54,7 @@
and follow the instructions there for anonymous SVN access.
</p>
<a name="boost_chrono.users_guide.getting_started.install.where_to_install__emphasis_role__bold__boost_chrono__emphasis___"></a><h5>
-<a name="id4818321"></a>
+<a name="id4817997"></a>
<a href="getting_started.html#boost_chrono.users_guide.getting_started.install.where_to_install__emphasis_role__bold__boost_chrono__emphasis___">Where
to install <span class="bold"><strong>Boost.Chrono</strong></span>? </a>
</h5>
@@ -70,7 +70,7 @@
variable. Any help is welcome.
</p>
<a name="boost_chrono.users_guide.getting_started.install.building__emphasis_role__bold__boost_chrono__emphasis__"></a><h5>
-<a name="id4818363"></a>
+<a name="id4818039"></a>
<a href="getting_started.html#boost_chrono.users_guide.getting_started.install.building__emphasis_role__bold__boost_chrono__emphasis__">Building
<span class="bold"><strong>Boost.Chrono</strong></span> </a>
</h5>
@@ -81,7 +81,7 @@
<pre class="programlisting"><span class="identifier">bjam</span> <span class="identifier">libs</span><span class="special">/</span><span class="identifier">chrono</span><span class="special">/</span><span class="identifier">build</span>
</pre>
<a name="boost_chrono.users_guide.getting_started.install.requirements"></a><h5>
-<a name="id4818431"></a>
+<a name="id4818107"></a>
<a href="getting_started.html#boost_chrono.users_guide.getting_started.install.requirements">Requirements</a>
</h5>
<p>
@@ -144,7 +144,7 @@
</dl>
</div>
<a name="boost_chrono.users_guide.getting_started.install.building_an_executable_that_uses__emphasis_role__bold__boost_chrono__emphasis__"></a><h5>
-<a name="id4818679"></a>
+<a name="id4818355"></a>
<a href="getting_started.html#boost_chrono.users_guide.getting_started.install.building_an_executable_that_uses__emphasis_role__bold__boost_chrono__emphasis__">Building
an executable that uses <span class="bold"><strong>Boost.Chrono</strong></span>
</a>
@@ -154,7 +154,7 @@
with the Boost System library.
</p>
<a name="boost_chrono.users_guide.getting_started.install.exceptions_safety_"></a><h5>
-<a name="id4818715"></a>
+<a name="id4818391"></a>
<a href="getting_started.html#boost_chrono.users_guide.getting_started.install.exceptions_safety_">Exceptions
safety </a>
</h5>
@@ -163,7 +163,7 @@
of exception safety as long as the underlying parameters provide it.
</p>
<a name="boost_chrono.users_guide.getting_started.install.thread_safety_"></a><h5>
-<a name="id4818742"></a>
+<a name="id4818418"></a>
<a href="getting_started.html#boost_chrono.users_guide.getting_started.install.thread_safety_">Thread
safety </a>
</h5>
@@ -171,7 +171,7 @@
All functions in the library are thread-unsafe except when noted explicitly.
</p>
<a name="boost_chrono.users_guide.getting_started.install.tested_compilers_"></a><h5>
-<a name="id4818766"></a>
+<a name="id4818442"></a>
<a href="getting_started.html#boost_chrono.users_guide.getting_started.install.tested_compilers_">Tested
compilers </a>
</h5>
Modified: sandbox/chrono/libs/chrono/doc/html/boost_chrono/users_guide/tutorial.html
==============================================================================
--- sandbox/chrono/libs/chrono/doc/html/boost_chrono/users_guide/tutorial.html (original)
+++ sandbox/chrono/libs/chrono/doc/html/boost_chrono/users_guide/tutorial.html 2010-06-26 11:18:46 EDT (Sat, 26 Jun 2010)
@@ -81,10 +81,10 @@
to get the common type of inter-type with explicit conversions?</a>
</h5></div></div></div>
<p>
- The default definition of <code class="computeroutput"><span class="identifier">common_type</span></code>
- demands the conversion be implicit. However the trait can be specialized
- for user-defined types which want to limit their inter-type conversions
- to explicit, and yet still want to interoperate with the <code class="computeroutput"><span class="identifier">common_type</span></code> facility.
+ The default definition of link_text demands the conversion be implicit.
+ However the trait can be specialized for user-defined types which want
+ to limit their inter-type conversions to explicit, and yet still want
+ to interoperate with the link_text facility.
</p>
</div>
</div>
Modified: sandbox/chrono/libs/chrono/doc/html/index.html
==============================================================================
--- sandbox/chrono/libs/chrono/doc/html/index.html (original)
+++ sandbox/chrono/libs/chrono/doc/html/index.html 2010-06-26 11:18:46 EDT (Sat, 26 Jun 2010)
@@ -101,7 +101,7 @@
</table></div>
</div>
<table xmlns:rev="http://www.cs.rpi.edu/~gregod/boost/tools/doc/revision" width="100%"><tr>
-<td align="left"><p><small>Last revised: June 26, 2010 at 02:41:06 GMT</small></p></td>
+<td align="left"><p><small>Last revised: June 26, 2010 at 15:15:54 GMT</small></p></td>
<td align="right"><div class="copyright-footer"></div></td>
</tr></table>
<hr>
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