|
Boost.PreprocessorExamples |
array_arithmetic.c | Implements over 2200 functions for 1-dimensional arithmetic array manipulation in C. The idea is to use preprocessor data structures, lists and tuples, for storing metainformation to be used for generating the actual C code. |
catch_builtin.cpp | Demonstrates the usage of lists and BOOST_PP_LIST_FOR_EACH(). |
count_down.c | Trivial example of using BOOST_PP_WHILE() that simply counts down from N to 0 ultimately expanding to a 0. |
delay.c | Implements a macro whose expansion takes exponential amount of time. |
duffs_device.c | Uses the preprocessor library to implement a generalized macro for implementing a Duff's Device. |
is_integral.cpp | Demonstrates the usage of preprocessor lists for generating C++ code. |
linear_fib.c | Shows how BOOST_PP_WHILE() can be used for implementing macros. |
note.c | Shows how BOOST_PP_STRINGIZE() can be used to allow macro expansion before stringization. |
repeat_2d.c | Implements a generalized macro for 2D repetition using the simple repetition primitives of the preprocessor library. |
static_assert.c | Shows how BOOST_PP_CAT() can be used to allow macro expansion before token concatenation. |
subscript_layer.cpp | Shows how BOOST_PP_EMPTY can be used as an unused or empty parameter. |
Revised
© Copyright Housemarque Oy 2002
Permission to copy, use, modify, sell and distribute this document is granted provided this copyright notice appears in all copies. This document is provided "as is" without express or implied warranty, and with no claim as to its suitability for any purpose.