3 <meta content=
"text/html; charset=windows-1252" http-equiv=
"content-type">
4 <title>BOOST_PP_TUPLE_REPLACE
</title>
5 <link rel=
"stylesheet" type=
"text/css" href=
"../styles.css">
8 <div style=
"margin-left: 0px;"> The
<b>BOOST_PP_TUPLE_REPLACE
</b> macro
9 replaces an element in a
<i>tuple
</i>.
</div>
11 <div class=
"code"> <b>BOOST_PP_TUPLE_REPLACE
</b>(
<i>tuple
</i>,
<i>i
</i>,
<i>elem
</i>)
12 <a href=
"../topics/variadic_macros.html#VNotation"><sup>(v)
</sup></a></div>
16 <dd> A
<i>tuple
</i> to replace an element in.
</dd>
18 <dd> The zero-based position in
<i>tuple
</i> of the element to be
19 replaced.
Valid values range from
<i>0</i> to
<b>BOOST_PP_TUPLE_SIZE
</b>(
<i>tuple
</i>)
22 <dd> The replacement element.
</dd>
25 <div> This macro uses
<b>BOOST_PP_WHILE
</b> interally.
Therefore, to
26 use the
<i>d
</i> parameter passed from other macros that use
<b>BOOST_PP_WHILE
</b>,
27 see
<b>BOOST_PP_TUPLE_REPLACE_D
</b>.
</div>
30 <li><a href=
"tuple_replace_d.html">BOOST_PP_TUPLE_REPLACE_D
</a></li>
33 <div> <b>Header:
</b> <a href=
"../headers/tuple/replace.html"><boost/preprocessor/tuple/replace.hpp
></a>
37 <pre>#include
<<a href=
"../headers/tuple/replace.html">boost/preprocessor/tuple/replace.hpp
</a>>
39 #define TUPLE (a, x, c)
41 <a href=
"tuple_replace.html">BOOST_PP_TUPLE_REPLACE
</a>(TUPLE,
1, b) // expands to (a, b, c))
44 <div style=
"margin-left: 0px;"> <i>© Copyright Edward Diener
2013</i> </div>
45 <div style=
"margin-left: 0px;">
46 <p><small>Distributed under the Boost Software License, Version
1.0. (See
47 accompanying file
<a href=
"../../../../LICENSE_1_0.txt">LICENSE_1_0.txt
</a>
48 or copy at
<a href=
"http://www.boost.org/LICENSE_1_0.txt">www.boost.org/LICENSE_1_0.txt
</a>)
</small></p>