Added requirements on numeric parameters

[SVN r13460]
This commit is contained in:
Vesa Karvonen
2002-04-12 12:16:05 +00:00
parent 06ff87a86c
commit 336749e0ae
46 changed files with 106 additions and 20 deletions

View File

@ -29,6 +29,9 @@
<h2><a name="BOOST_PP_ADD">#define BOOST_PP_ADD</a>(X,Y)</h2>
<p>Expands to the sum of <code>X</code> and <code>Y</code>.</p>
<p>Both <code>X</code> and <code>Y</code> must expand to integer literals
in the range [0, <a href="limits.htm#BOOST_PP_LIMIT_MAG">BOOST_PP_LIMIT_MAG</a>].</p>
<p>For example, <code><a href="arithmetic_add.htm#BOOST_PP_ADD">BOOST_PP_ADD</a>(4,3)</code> expands to <code>7</code> (a
single token).</p>

View File

@ -29,6 +29,9 @@
<h2><a name="BOOST_PP_DIV">#define BOOST_PP_DIV</a>(X,Y)</h2>
<p>Expands to the quotient of <code>X</code> and <code>Y</code>.</p>
<p>Both <code>X</code> and <code>Y</code> must expand to integer literals
in the range [0, <a href="limits.htm#BOOST_PP_LIMIT_MAG">BOOST_PP_LIMIT_MAG</a>].</p>
<p>For example, <code><a href="arithmetic_div.htm#BOOST_PP_DIV">BOOST_PP_DIV</a>(4,3)</code> expands to <code>1</code> (a
single token).</p>

View File

@ -29,6 +29,9 @@
<h2><a name="BOOST_PP_MOD">#define BOOST_PP_MOD</a>(X,Y)</h2>
<p>Expands to the remainder of <code>X</code> and <code>Y</code>.</p>
<p>Both <code>X</code> and <code>Y</code> must expand to integer literals
in the range [0, <a href="limits.htm#BOOST_PP_LIMIT_MAG">BOOST_PP_LIMIT_MAG</a>].</p>
<p>For example, <code><a href="arithmetic_mod.htm#BOOST_PP_MOD">BOOST_PP_MOD</a>(4,3)</code> expands to <code>1</code> (a
single token).</p>

View File

@ -29,6 +29,9 @@
<h2><a name="BOOST_PP_MUL">#define BOOST_PP_MUL</a>(X,Y)</h2>
<p>Expands to the product of <code>X</code> and <code>Y</code>.</p>
<p>Both <code>X</code> and <code>Y</code> must expand to integer literals
in the range [0, <a href="limits.htm#BOOST_PP_LIMIT_MAG">BOOST_PP_LIMIT_MAG</a>].</p>
<p>For example, <code><a href="arithmetic_mul.htm#BOOST_PP_MUL">BOOST_PP_MUL</a>(4,3)</code> expands to <code>12</code> (a
single token).</p>

View File

@ -29,6 +29,9 @@
<h2><a name="BOOST_PP_SUB">#define BOOST_PP_SUB</a>(X,Y)</h2>
<p>Expands to the difference of <code>X</code> and <code>Y</code>.</p>
<p>Both <code>X</code> and <code>Y</code> must expand to integer literals
in the range [0, <a href="limits.htm#BOOST_PP_LIMIT_MAG">BOOST_PP_LIMIT_MAG</a>].</p>
<p>For example, <code><a href="arithmetic_sub.htm#BOOST_PP_SUB">BOOST_PP_SUB</a>(4,3)</code> expands to <code>1</code> (a
single token).</p>

View File

@ -30,7 +30,7 @@
<p>Expands to nothing if <code>COND != 0</code> and to <code>MSG</code> if
<code>COND == 0</code>.</p>
<p><code>COND</code> must expand to an integer literal.</p>
<p><code>COND</code> must expand to an integer literal in the range [0, <a href="limits.htm#BOOST_PP_LIMIT_MAG">BOOST_PP_LIMIT_MAG</a>].</p>
<p>For example, <code><a href="assert_msg.htm#BOOST_PP_ASSERT_MSG">BOOST_PP_ASSERT_MSG</a>(1,A BUG!)</code> expands to <code>A BUG!</code>.</p>

View File

@ -30,7 +30,7 @@
<p>Expands to a comma if <code>COND != 0</code> and nothing if
<code>COND == 0</code>.</p>
<p><code>COND</code> must expand to an integer literal.</p>
<p><code>COND</code> must expand to an integer literal in the range [0, <a href="limits.htm#BOOST_PP_LIMIT_MAG">BOOST_PP_LIMIT_MAG</a>].</p>
<p>For example, <code><a href="comma_if.htm#BOOST_PP_COMMA_IF">BOOST_PP_COMMA_IF</a>(0)</code> expands to nothing.</p>

View File

@ -30,7 +30,8 @@
<p>Expands to <code>1</code> if <code>X == Y</code> and <code>0</code>
otherwise.</p>
<p>Both <code>X</code> and <code>Y</code> must expand to integer literals.</p>
<p>Both <code>X</code> and <code>Y</code> must expand to integer literals
in the range [0, <a href="limits.htm#BOOST_PP_LIMIT_MAG">BOOST_PP_LIMIT_MAG</a>].</p>
<p>For example, <code><a href="comparison_equal.htm#BOOST_PP_EQUAL">BOOST_PP_EQUAL</a>(4,4)</code> expands to <code>1</code>.</p>

View File

@ -30,7 +30,8 @@
<p>Expands to <code>1</code> if <code>X &gt; Y</code> and <code>0</code>
otherwise.</p>
<p>Both <code>X</code> and <code>Y</code> must expand to integer literals.</p>
<p>Both <code>X</code> and <code>Y</code> must expand to integer literals
in the range [0, <a href="limits.htm#BOOST_PP_LIMIT_MAG">BOOST_PP_LIMIT_MAG</a>].</p>
<p>For example, <code><a href="comparison_greater.htm#BOOST_PP_GREATER">BOOST_PP_GREATER</a>(4,3)</code> expands to <code>1</code>.</p>

View File

@ -30,7 +30,8 @@
<p>Expands to <code>1</code> if <code>X &gt;= Y</code> and <code>0</code>
otherwise.</p>
<p>Both <code>X</code> and <code>Y</code> must expand to integer literals.</p>
<p>Both <code>X</code> and <code>Y</code> must expand to integer literals
in the range [0, <a href="limits.htm#BOOST_PP_LIMIT_MAG">BOOST_PP_LIMIT_MAG</a>].</p>
<p>For example, <code><a href="comparison_greater_equal.htm#BOOST_PP_GREATER_EQUAL">BOOST_PP_GREATER_EQUAL</a>(1,3)</code> expands to <code>0</code>.</p>

View File

@ -30,7 +30,8 @@
<p>Expands to <code>1</code> if <code>X &lt; Y</code> and <code>0</code>
otherwise.</p>
<p>Both <code>X</code> and <code>Y</code> must expand to integer literals.</p>
<p>Both <code>X</code> and <code>Y</code> must expand to integer literals
in the range [0, <a href="limits.htm#BOOST_PP_LIMIT_MAG">BOOST_PP_LIMIT_MAG</a>].</p>
<p>For example, <code><a href="comparison_less.htm#BOOST_PP_LESS">BOOST_PP_LESS</a>(2,6)</code> expands to <code>1</code>.</p>

View File

@ -30,7 +30,8 @@
<p>Expands to <code>1</code> if <code>X &lt;= Y</code> and <code>0</code>
otherwise.</p>
<p><code>X</code> must expand to an integer literal.</p>
<p>Both <code>X</code> and <code>Y</code> must expand to integer literals
in the range [0, <a href="limits.htm#BOOST_PP_LIMIT_MAG">BOOST_PP_LIMIT_MAG</a>].</p>
<p>For example, <code><a href="comparison_less_equal.htm#BOOST_PP_LESS_EQUAL">BOOST_PP_LESS_EQUAL</a>(7,5)</code> expands to <code>0</code>.</p>

View File

@ -30,7 +30,8 @@
<p>Expands to <code>1</code> if <code>X != Y</code> and <code>0</code>
otherwise.</p>
<p>Both <code>X</code> and <code>Y</code> must expand to integer literals.</p>
<p>Both <code>X</code> and <code>Y</code> must expand to integer literals
in the range [0, <a href="limits.htm#BOOST_PP_LIMIT_MAG">BOOST_PP_LIMIT_MAG</a>].</p>
<p>For example, <code><a href="comparison_not_equal.htm#BOOST_PP_NOT_EQUAL">BOOST_PP_NOT_EQUAL</a>(4,4)</code> expands to <code>0</code>.</p>

View File

@ -29,7 +29,7 @@
<h2><a name="BOOST_PP_EXPR_IF">#define BOOST_PP_EXPR_IF</a>(COND,EXPR)</h2>
<p>Expands to <code>EXPR</code> if <code>COND != 0</code> and to nothing if <code>COND == 0</code>.</p>
<p><code>COND</code> must expand to an integer literal.</p>
<p><code>COND</code> must expand to an integer literal in the range [0, <a href="limits.htm#BOOST_PP_LIMIT_MAG">BOOST_PP_LIMIT_MAG</a>].</p>
<p>For example, <code><a href="expr_if.htm#BOOST_PP_EXPR_IF">BOOST_PP_EXPR_IF</a>(1,^)</code> expands to <code>^</code>.</p>

View File

@ -30,7 +30,7 @@
<p>Expands to <code>THEN</code> if <code>COND != 0</code> and <code>ELSE</code> if
<code>COND == 0</code>.</p>
<p><code>COND</code> must expand to an integer literal.</p>
<p><code>COND</code> must expand to an integer literal in the range [0, <a href="limits.htm#BOOST_PP_LIMIT_MAG">BOOST_PP_LIMIT_MAG</a>].</p>
<p>For example, <code><a href="if.htm#BOOST_PP_IF">BOOST_PP_IF</a>(0,1,2)</code> expands to <code>2</code>.</p>

View File

@ -29,6 +29,9 @@
<h2><a name="BOOST_PP_AND">#define BOOST_PP_AND</a>(X,Y)</h2>
<p>Expands to the logical AND of the operands.</p>
<p>Both <code>X</code> and <code>Y</code> must expand to integer literals
in the range [0, <a href="limits.htm#BOOST_PP_LIMIT_MAG">BOOST_PP_LIMIT_MAG</a>].</p>
<p>For example, <code><a href="logical_and.htm#BOOST_PP_AND">BOOST_PP_AND</a>(0,5)</code> expands to <code>0</code> (a single token).</p>
<h3>Test</h3>

View File

@ -29,6 +29,8 @@
<h2><a name="BOOST_PP_BOOL">#define BOOST_PP_BOOL</a>(X)</h2>
<p>Expands to <code>0</code> if <code>X == 0</code> and <code>1</code> if <code>X != 0</code>.</p>
<p><code>X</code> must be an integer literal in the range [0, <a href="limits.htm#BOOST_PP_LIMIT_MAG">BOOST_PP_LIMIT_MAG</a>].</p>
<p>For example, <code><a href="logical_bool.htm#BOOST_PP_BOOL">BOOST_PP_BOOL</a>(3)</code> expands to <code>1</code>.</p>
<hr>

View File

@ -29,6 +29,9 @@
<h2><a name="BOOST_PP_NOR">#define BOOST_PP_NOR</a>(X,Y)</h2>
<p>Expands to the logical NEITHER OR of the operands.</p>
<p>Both <code>X</code> and <code>Y</code> must expand to integer literals
in the range [0, <a href="limits.htm#BOOST_PP_LIMIT_MAG">BOOST_PP_LIMIT_MAG</a>].</p>
<p>For example, <code><a href="logical_nor.htm#BOOST_PP_NOR">BOOST_PP_NOR</a>(0,5)</code> expands to <code>0</code> (a single token).</p>
<h3>Test</h3>

View File

@ -29,6 +29,8 @@
<h2><a name="BOOST_PP_NOT">#define BOOST_PP_NOT</a>(X)</h2>
<p>Expands to the logical NOT of the operand.</p>
<p><code>X</code> must be an integer literal in the range [0, <a href="limits.htm#BOOST_PP_LIMIT_MAG">BOOST_PP_LIMIT_MAG</a>].</p>
<p>For example, <code><a href="logical_not.htm#BOOST_PP_NOT">BOOST_PP_NOT</a>(0)</code> expands to <code>1</code> (a single token).</p>
<h3>Test</h3>

View File

@ -29,6 +29,9 @@
<h2><a name="BOOST_PP_OR">#define BOOST_PP_OR</a>(X,Y)</h2>
<p>Expands to the logical OR of the operands.</p>
<p>Both <code>X</code> and <code>Y</code> must expand to integer literals
in the range [0, <a href="limits.htm#BOOST_PP_LIMIT_MAG">BOOST_PP_LIMIT_MAG</a>].</p>
<p>For example, <code><a href="logical_or.htm#BOOST_PP_OR">BOOST_PP_OR</a>(0,2)</code> expands to <code>1</code> (a single token).</p>
<h3>Test</h3>

View File

@ -29,6 +29,9 @@
<h2><a name="BOOST_PP_XOR">#define BOOST_PP_XOR</a>(X,Y)</h2>
<p>Expands to the logical EXCLUSIVE OR of the operands.</p>
<p>Both <code>X</code> and <code>Y</code> must expand to integer literals
in the range [0, <a href="limits.htm#BOOST_PP_LIMIT_MAG">BOOST_PP_LIMIT_MAG</a>].</p>
<p>For example, <code><a href="logical_xor.htm#BOOST_PP_XOR">BOOST_PP_XOR</a>(1,2)</code> expands to <code>0</code> (a single token).</p>
<h3>Test</h3>

View File

@ -29,6 +29,9 @@
<h2><a name="BOOST_PP_MAX">#define BOOST_PP_MAX</a>(X,Y)</h2>
<p>Expands to the maximum of <code>X</code> and <code>Y</code>.</p>
<p>Both <code>X</code> and <code>Y</code> must expand to integer literals
in the range [0, <a href="limits.htm#BOOST_PP_LIMIT_MAG">BOOST_PP_LIMIT_MAG</a>].</p>
<p>For example, <code><a href="max.htm#BOOST_PP_MAX">BOOST_PP_MAX</a>(5,7)</code> expands to <code>7</code> (a
single token).</p>

View File

@ -29,6 +29,9 @@
<h2><a name="BOOST_PP_MIN">#define BOOST_PP_MIN</a>(X,Y)</h2>
<p>Expands to the minimum of <code>X</code> and <code>Y</code>.</p>
<p>Both <code>X</code> and <code>Y</code> must expand to integer literals
in the range [0, <a href="limits.htm#BOOST_PP_LIMIT_MAG">BOOST_PP_LIMIT_MAG</a>].</p>
<p>For example, <code><a href="min.htm#BOOST_PP_MIN">BOOST_PP_MIN</a>(5,7)</code> expands to <code>5</code> (a
single token).</p>

View File

@ -20,6 +20,9 @@
/** <p>Expands to the sum of <code>X</code> and <code>Y</code>.</p>
<p>Both <code>X</code> and <code>Y</code> must expand to integer literals
in the range [0, BOOST_PP_LIMIT_MAG].</p>
<p>For example, <code>BOOST_PP_ADD(4,3)</code> expands to <code>7</code> (a
single token).</p>

View File

@ -18,6 +18,9 @@
/** <p>Expands to the quotient of <code>X</code> and <code>Y</code>.</p>
<p>Both <code>X</code> and <code>Y</code> must expand to integer literals
in the range [0, BOOST_PP_LIMIT_MAG].</p>
<p>For example, <code>BOOST_PP_DIV(4,3)</code> expands to <code>1</code> (a
single token).</p>

View File

@ -17,6 +17,9 @@
/** <p>Expands to the remainder of <code>X</code> and <code>Y</code>.</p>
<p>Both <code>X</code> and <code>Y</code> must expand to integer literals
in the range [0, BOOST_PP_LIMIT_MAG].</p>
<p>For example, <code>BOOST_PP_MOD(4,3)</code> expands to <code>1</code> (a
single token).</p>

View File

@ -17,6 +17,9 @@
/** <p>Expands to the product of <code>X</code> and <code>Y</code>.</p>
<p>Both <code>X</code> and <code>Y</code> must expand to integer literals
in the range [0, BOOST_PP_LIMIT_MAG].</p>
<p>For example, <code>BOOST_PP_MUL(4,3)</code> expands to <code>12</code> (a
single token).</p>

View File

@ -19,6 +19,9 @@
/** <p>Expands to the difference of <code>X</code> and <code>Y</code>.</p>
<p>Both <code>X</code> and <code>Y</code> must expand to integer literals
in the range [0, BOOST_PP_LIMIT_MAG].</p>
<p>For example, <code>BOOST_PP_SUB(4,3)</code> expands to <code>1</code> (a
single token).</p>

View File

@ -19,7 +19,7 @@
/** <p>Expands to nothing if <code>COND != 0</code> and to <code>MSG</code> if
<code>COND == 0</code>.</p>
<p><code>COND</code> must expand to an integer literal.</p>
<p><code>COND</code> must expand to an integer literal in the range [0, BOOST_PP_LIMIT_MAG].</p>
<p>For example, <code>BOOST_PP_ASSERT_MSG(1,A BUG!)</code> expands to <code>A BUG!</code>.</p>
*/

View File

@ -20,7 +20,7 @@
/** <p>Expands to a comma if <code>COND != 0</code> and nothing if
<code>COND == 0</code>.</p>
<p><code>COND</code> must expand to an integer literal.</p>
<p><code>COND</code> must expand to an integer literal in the range [0, BOOST_PP_LIMIT_MAG].</p>
<p>For example, <code>BOOST_PP_COMMA_IF(0)</code> expands to nothing.</p>
*/

View File

@ -19,7 +19,8 @@
/** <p>Expands to <code>1</code> if <code>X == Y</code> and <code>0</code>
otherwise.</p>
<p>Both <code>X</code> and <code>Y</code> must expand to integer literals.</p>
<p>Both <code>X</code> and <code>Y</code> must expand to integer literals
in the range [0, BOOST_PP_LIMIT_MAG].</p>
<p>For example, <code>BOOST_PP_EQUAL(4,4)</code> expands to <code>1</code>.</p>

View File

@ -18,7 +18,8 @@
/** <p>Expands to <code>1</code> if <code>X &gt; Y</code> and <code>0</code>
otherwise.</p>
<p>Both <code>X</code> and <code>Y</code> must expand to integer literals.</p>
<p>Both <code>X</code> and <code>Y</code> must expand to integer literals
in the range [0, BOOST_PP_LIMIT_MAG].</p>
<p>For example, <code>BOOST_PP_GREATER(4,3)</code> expands to <code>1</code>.</p>

View File

@ -18,7 +18,8 @@
/** <p>Expands to <code>1</code> if <code>X &gt;= Y</code> and <code>0</code>
otherwise.</p>
<p>Both <code>X</code> and <code>Y</code> must expand to integer literals.</p>
<p>Both <code>X</code> and <code>Y</code> must expand to integer literals
in the range [0, BOOST_PP_LIMIT_MAG].</p>
<p>For example, <code>BOOST_PP_GREATER_EQUAL(1,3)</code> expands to <code>0</code>.</p>

View File

@ -20,7 +20,8 @@
/** <p>Expands to <code>1</code> if <code>X &lt; Y</code> and <code>0</code>
otherwise.</p>
<p>Both <code>X</code> and <code>Y</code> must expand to integer literals.</p>
<p>Both <code>X</code> and <code>Y</code> must expand to integer literals
in the range [0, BOOST_PP_LIMIT_MAG].</p>
<p>For example, <code>BOOST_PP_LESS(2,6)</code> expands to <code>1</code>.</p>

View File

@ -19,7 +19,8 @@
/** <p>Expands to <code>1</code> if <code>X &lt;= Y</code> and <code>0</code>
otherwise.</p>
<p><code>X</code> must expand to an integer literal.</p>
<p>Both <code>X</code> and <code>Y</code> must expand to integer literals
in the range [0, BOOST_PP_LIMIT_MAG].</p>
<p>For example, <code>BOOST_PP_LESS_EQUAL(7,5)</code> expands to <code>0</code>.</p>

View File

@ -20,7 +20,8 @@
/** <p>Expands to <code>1</code> if <code>X != Y</code> and <code>0</code>
otherwise.</p>
<p>Both <code>X</code> and <code>Y</code> must expand to integer literals.</p>
<p>Both <code>X</code> and <code>Y</code> must expand to integer literals
in the range [0, BOOST_PP_LIMIT_MAG].</p>
<p>For example, <code>BOOST_PP_NOT_EQUAL(4,4)</code> expands to <code>0</code>.</p>

View File

@ -17,7 +17,7 @@
/** <p>Expands to <code>EXPR</code> if <code>COND != 0</code> and to nothing if <code>COND == 0</code>.</p>
<p><code>COND</code> must expand to an integer literal.</p>
<p><code>COND</code> must expand to an integer literal in the range [0, BOOST_PP_LIMIT_MAG].</p>
<p>For example, <code>BOOST_PP_EXPR_IF(1,^)</code> expands to <code>^</code>.</p>

View File

@ -19,7 +19,7 @@
/** <p>Expands to <code>THEN</code> if <code>COND != 0</code> and <code>ELSE</code> if
<code>COND == 0</code>.</p>
<p><code>COND</code> must expand to an integer literal.</p>
<p><code>COND</code> must expand to an integer literal in the range [0, BOOST_PP_LIMIT_MAG].</p>
<p>For example, <code>BOOST_PP_IF(0,1,2)</code> expands to <code>2</code>.</p>

View File

@ -17,6 +17,9 @@
/** <p>Expands to the logical AND of the operands.</p>
<p>Both <code>X</code> and <code>Y</code> must expand to integer literals
in the range [0, BOOST_PP_LIMIT_MAG].</p>
<p>For example, <code>BOOST_PP_AND(0,5)</code> expands to <code>0</code> (a single token).</p>
<h3>Test</h3>

View File

@ -15,6 +15,8 @@
/** <p>Expands to <code>0</code> if <code>X == 0</code> and <code>1</code> if <code>X != 0</code>.</p>
<p><code>X</code> must be an integer literal in the range [0, BOOST_PP_LIMIT_MAG].</p>
<p>For example, <code>BOOST_PP_BOOL(3)</code> expands to <code>1</code>.</p>
*/
#define BOOST_PP_BOOL(X) BOOST_PP_BOOL_DELAY(X)

View File

@ -17,6 +17,9 @@
/** <p>Expands to the logical NEITHER OR of the operands.</p>
<p>Both <code>X</code> and <code>Y</code> must expand to integer literals
in the range [0, BOOST_PP_LIMIT_MAG].</p>
<p>For example, <code>BOOST_PP_NOR(0,5)</code> expands to <code>0</code> (a single token).</p>
<h3>Test</h3>

View File

@ -17,6 +17,8 @@
/** <p>Expands to the logical NOT of the operand.</p>
<p><code>X</code> must be an integer literal in the range [0, BOOST_PP_LIMIT_MAG].</p>
<p>For example, <code>BOOST_PP_NOT(0)</code> expands to <code>1</code> (a single token).</p>
<h3>Test</h3>

View File

@ -17,6 +17,9 @@
/** <p>Expands to the logical OR of the operands.</p>
<p>Both <code>X</code> and <code>Y</code> must expand to integer literals
in the range [0, BOOST_PP_LIMIT_MAG].</p>
<p>For example, <code>BOOST_PP_OR(0,2)</code> expands to <code>1</code> (a single token).</p>
<h3>Test</h3>

View File

@ -17,6 +17,9 @@
/** <p>Expands to the logical EXCLUSIVE OR of the operands.</p>
<p>Both <code>X</code> and <code>Y</code> must expand to integer literals
in the range [0, BOOST_PP_LIMIT_MAG].</p>
<p>For example, <code>BOOST_PP_XOR(1,2)</code> expands to <code>0</code> (a single token).</p>
<h3>Test</h3>

View File

@ -18,6 +18,9 @@
/** <p>Expands to the maximum of <code>X</code> and <code>Y</code>.</p>
<p>Both <code>X</code> and <code>Y</code> must expand to integer literals
in the range [0, BOOST_PP_LIMIT_MAG].</p>
<p>For example, <code>BOOST_PP_MAX(5,7)</code> expands to <code>7</code> (a
single token).</p>

View File

@ -18,6 +18,9 @@
/** <p>Expands to the minimum of <code>X</code> and <code>Y</code>.</p>
<p>Both <code>X</code> and <code>Y</code> must expand to integer literals
in the range [0, BOOST_PP_LIMIT_MAG].</p>
<p>For example, <code>BOOST_PP_MIN(5,7)</code> expands to <code>5</code> (a
single token).</p>