intercept.html 2.0 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051
  1. <html>
  2. <head>
  3. <title>BOOST_PP_INTERCEPT</title>
  4. <link rel="stylesheet" type="text/css" href="../styles.css">
  5. </head>
  6. <body>
  7. <div style="margin-left: 0px;">
  8. The <b>BOOST_PP_INTERCEPT</b> macro intercepts a numeric concatenation and expands to nothing.
  9. </div>
  10. <h4>Usage</h4>
  11. <div class="code">
  12. <b>BOOST_PP_INTERCEPT</b>
  13. </div>
  14. <h4>Remarks</h4>
  15. <div>
  16. This macro is used to intercept concatenations performed by various other library constructs.&nbsp;
  17. It is typically used after other text to prevent eat the concatenation expand to nothing.&nbsp;
  18. This macro can only intercept integer constants in the range of <i>0</i> to <b>BOOST_PP_LIMIT_MAG</b>.
  19. </div>
  20. <h4>See Also</h4>
  21. <ul>
  22. <li><a href="limit_mag.html">BOOST_PP_LIMIT_MAG</a></li>
  23. </ul>
  24. <h4>Requirements</h4>
  25. <div>
  26. <b>Header:</b> &nbsp;<a href="../headers/facilities/intercept.html">&lt;boost/preprocessor/facilities/intercept.hpp&gt;</a>
  27. </div>
  28. <h4>Sample Code</h4>
  29. <div><pre>
  30. #include &lt;<a href="../headers/facilities/intercept.html">boost/preprocessor/facilities/intercept.hpp</a>&gt;
  31. #include &lt;<a href="../headers/repetition/enum_binary_params.html">boost/preprocessor/repetition/enum_binary_params.hpp</a>&gt;
  32. <a href="enum_binary_params.html">BOOST_PP_ENUM_BINARY_PARAMS</a>(3, class T, = U)
  33. // expands to class T0 = U0, class T1 = U1, class T2 = U2
  34. <a href="enum_binary_params.html">BOOST_PP_ENUM_BINARY_PARAMS</a>(3, class T, = int <a href="intercept.html">BOOST_PP_INTERCEPT</a>)
  35. // expands to class T0 = int, class T1 = int, class T2 = int
  36. </pre></div>
  37. <hr size="1">
  38. <div style="margin-left: 0px;">
  39. <i>© Copyright <a href="http://www.housemarque.com" target="_top">Housemarque Oy</a> 2002</i>
  40. </br><i>© Copyright Paul Mensonides 2002</i>
  41. </div>
  42. <div style="margin-left: 0px;">
  43. <p><small>Distributed under the Boost Software License, Version 1.0. (See
  44. accompanying file <a href="../../../../LICENSE_1_0.txt">LICENSE_1_0.txt</a> or
  45. copy at <a href=
  46. "http://www.boost.org/LICENSE_1_0.txt">www.boost.org/LICENSE_1_0.txt</a>)</small></p>
  47. </div>
  48. </body>
  49. </html>