update the docs
[SVN r17836]
This commit is contained in:
1 parent
747dae9e6c
commit
a69baa5eae
91 files changed
+1213
-501
No files matched your search
+12
-12
@@ -1,13 +1,13 @@
|
||||
<!doctype html public "-//ietf//dtd html//en">
|
||||
<html><head><title>boost::mpl::Reference/at c</title>
|
||||
<html><head><title>boost::mpl::at_c</title>
|
||||
<link rel="stylesheet" href="../mpl_wiki.css">
|
||||
</head><body bgcolor="white">
|
||||
<h1><a href="../Table_of_Content.html"><img src="../mpl_logo.jpg" alt="[Home]" border=0 align="right"></a>at_c</h1><h3>Synopsis</h3>
|
||||
<h1><a href="../Table_of_Contents.html"><img src="../mpl_logo.jpg" alt="[Home]" border=0 align="right"></a>at_c</h1><h3>Synopsis</h3>
|
||||
<p>
|
||||
<pre>
|
||||
template<
|
||||
long n
|
||||
, typename Sequence
|
||||
typename Sequence
|
||||
, long n
|
||||
>
|
||||
struct at_c
|
||||
{
|
||||
@@ -17,26 +17,26 @@ struct at_c
|
||||
<p>
|
||||
<h3>Description</h3>
|
||||
<p>
|
||||
Returns a type identical to the <code>n</code>-th element from the beginning of the sequence. <code>at_c<n,Sequence>::type</code> is a shorcut notation for <code>at< integral_c<long,n>, Sequence>::type</code>.
|
||||
Returns a type identical to the <code>n</code>-th element from the beginning of the sequence. <code>at_c<Sequence,n>::type</code> is a shorcut notation for <code>at< Sequence, integral_c<long,n> >::type</code>.
|
||||
<p>
|
||||
<h3>Definition</h3>
|
||||
<p>
|
||||
<pre>
|
||||
#include "<a href="../../../../../\boost/mpl/at.hpp">boost/mpl/at.hpp</a>"
|
||||
#include "<a href="../../../../../boost/mpl/at.hpp">boost/mpl/at.hpp</a>"
|
||||
</pre>
|
||||
<p>
|
||||
<h3>Parameters</h3>
|
||||
<table border="1">
|
||||
<tr><th> Parameter </th><th> Requirement </th><th> Description </th></tr>
|
||||
<tr><td><code>n</code></td><td>An compile-time integral constant</td><td>An offset from the beginning of the sequence that specifies the element to be retrieved. </td></tr>
|
||||
<tr><td><code>Sequence</code></td><td>A model of <a href="../Forward_Sequence.html">Forward Sequence</a></td><td>A sequence being examined. </td></tr>
|
||||
<tr><td><code>n</code></td><td>An compile-time integral constant</td><td>An offset from the beginning of the sequence that specifies the element to be retrieved. </td></tr>
|
||||
</table>
|
||||
<p>
|
||||
<h3>Expression semantics</h3>
|
||||
<p>
|
||||
<table border="1">
|
||||
<tr><th> Expression </th><th> Expression type </th><th> Precondition </th><th> Semantics </th><th> Postcondition </th></tr>
|
||||
<tr><td><code>typedef at_c<n,Sequence>::type t;</code></td><td>A type</td><td><code>0 <= n < size<Sequence>::type::value</code></td><td>Equivalent to <code>typedef at< integral_c<long,n>, Sequence>::type t;</code></td><td></td></tr>
|
||||
<tr><td><code>typedef at_c<Sequence,n>::type t;</code></td><td>A type</td><td><code>0 <= n < size<Sequence>::type::value</code></td><td>Equivalent to <code>typedef at< Sequence, integral_c<long,n> >::type t;</code></td><td></td></tr>
|
||||
</table>
|
||||
<p>
|
||||
<h3>Complexity</h3>
|
||||
@@ -47,13 +47,13 @@ Depends on the implementation of the particular sequence it is applied to. Linea
|
||||
<p>
|
||||
<pre>
|
||||
typedef <a href="../Reference/range_c.html">range_c</a><long,10,50> range;
|
||||
BOOST_STATIC_ASSERT(at_c<0,range>::type::value == 10);
|
||||
BOOST_STATIC_ASSERT(at_c<10,range>::type::value == 20);
|
||||
BOOST_STATIC_ASSERT(at_c<40,range>::type::value == 50);
|
||||
BOOST_STATIC_ASSERT(at_c<range,0>::type::value == 10);
|
||||
BOOST_STATIC_ASSERT(at_c<range,10>::type::value == 20);
|
||||
BOOST_STATIC_ASSERT(at_c<range,40>::type::value == 50);
|
||||
</pre>
|
||||
<p>
|
||||
<h3>See also</h3>
|
||||
<p>
|
||||
<a href="../Forward_Sequence.html">Forward Sequence</a>, <code><a href="../Reference/at.html">at</a></code>, <code><a href="../Reference/front.html">front</a></code>, <code><a href="../Reference/back.html">back</a></code>
|
||||
<p><hr>
|
||||
<a href="../Table_of_Content.html">Table of Content</a> | <a href="../Reference.html">Reference</a><br>Last edited July 17, 2002 3:50 am</body></html>
|
||||
<a href="../Table_of_Contents.html">Table of Contents</a><br>Last edited October 21, 2002 4:09 am</body></html>
|
||||
Reference in new issue
Block a user