forked from boostorg/preprocessor
Updated docs
[SVN r12687]
This commit is contained in:
@ -13,32 +13,12 @@
|
||||
* See http://www.boost.org for most recent version.
|
||||
*/
|
||||
|
||||
/** <P>Delays the stringization of X.</P>
|
||||
/** <p>Stringizes <code>X</code> after it is macro expanded.</p>
|
||||
|
||||
<P>For example,</P>
|
||||
|
||||
<PRE>
|
||||
#define NOTE(STR)\
|
||||
message(__FILE__ "(" BOOST_PP_STRINGIZE(__LINE__) ") : " STR)
|
||||
|
||||
// ...
|
||||
|
||||
#pragma NOTE("TBD!")
|
||||
</PRE>
|
||||
|
||||
<P>expands to:</P>
|
||||
|
||||
<PRE>
|
||||
#pragma message("examples.cpp" "(" "20" ") : " "TBD!")
|
||||
</PRE>
|
||||
|
||||
<P>The use of BOOST_PP_STRINGIZE() above lets the PP expand the __LINE__
|
||||
before stringizing it. If # would be used directly, the code would
|
||||
expand to:</P>
|
||||
|
||||
<PRE>
|
||||
#pragma message("examples.cpp" "(" "__LINE__" ") : " "TBD!")
|
||||
</PRE>
|
||||
<h3>Example</h3>
|
||||
<ul>
|
||||
<li><a href="../../example/note.c">note.c</a></li>
|
||||
</ul>
|
||||
*/
|
||||
#define BOOST_PP_STRINGIZE(X) BOOST_PP_STRINGIZE_DELAY(X)
|
||||
|
||||
@ -47,6 +27,6 @@ expand to:</P>
|
||||
#define BOOST_PP_DO_STRINGIZE(X) #X
|
||||
#endif
|
||||
|
||||
/** <P>Obsolete. Use BOOST_PP_STRINGIZE().</P> */
|
||||
/** <p>Obsolete. Use BOOST_PP_STRINGIZE().</p> */
|
||||
#define BOOST_PREPROCESSOR_STRINGIZE(E) BOOST_PP_STRINGIZE(E)
|
||||
#endif
|
||||
|
Reference in New Issue
Block a user