1<html> 2<head> 3<meta http-equiv="Content-Type" content="text/html; charset=UTF-8"> 4<title>Design</title> 5<link rel="stylesheet" href="../../../../../doc/src/boostbook.css" type="text/css"> 6<meta name="generator" content="DocBook XSL Stylesheets V1.79.1"> 7<link rel="home" href="../index.html" title="Chapter 1. The Variadic Macro Data Library 1.9"> 8<link rel="up" href="../index.html" title="Chapter 1. The Variadic Macro Data Library 1.9"> 9<link rel="prev" href="../BOOST_VMD_IS_VMD_TUPLE.html" title="Macro BOOST_VMD_IS_VMD_TUPLE"> 10<link rel="next" href="vmd_compilers.html" title="Compilers"> 11</head> 12<body bgcolor="white" text="black" link="#0000FF" vlink="#840084" alink="#0000FF"> 13<table cellpadding="2" width="100%"><tr> 14<td valign="top"><img alt="Boost C++ Libraries" width="277" height="86" src="../../../../../boost.png"></td> 15<td align="center"><a href="../../../../../index.html">Home</a></td> 16<td align="center"><a href="../../../../../libs/libraries.htm">Libraries</a></td> 17<td align="center"><a href="http://www.boost.org/users/people.html">People</a></td> 18<td align="center"><a href="http://www.boost.org/users/faq.html">FAQ</a></td> 19<td align="center"><a href="../../../../../more/index.htm">More</a></td> 20</tr></table> 21<hr> 22<div class="spirit-nav"> 23<a accesskey="p" href="../BOOST_VMD_IS_VMD_TUPLE.html"><img src="../../../../../doc/src/images/prev.png" alt="Prev"></a><a accesskey="u" href="../index.html"><img src="../../../../../doc/src/images/up.png" alt="Up"></a><a accesskey="h" href="../index.html"><img src="../../../../../doc/src/images/home.png" alt="Home"></a><a accesskey="n" href="vmd_compilers.html"><img src="../../../../../doc/src/images/next.png" alt="Next"></a> 24</div> 25<div class="section"> 26<div class="titlepage"><div><div><h2 class="title" style="clear: both"> 27<a name="variadic_macro_data.vmd_design"></a><a class="link" href="vmd_design.html" title="Design">Design</a> 28</h2></div></div></div> 29<p> 30 The initial impetus for creating this library was entirely practical. I had 31 been working on another library of macro functionality, which used Boost PP 32 functionality, and I realized that if I could use variadic macros with my other 33 library, the end-user usability for that library would be easier. Therefore 34 the initial main design goal of this library was to interoperate variadic macro 35 data with Boost PP in the easiest and clearest way possible. 36 </p> 37<p> 38 This led to the original versions of the library as an impetus for adding variadic 39 macro data support to Boost PP. While this was being done, but the variadic 40 macro data support had not yet been finalized in Boost PP, I still maintained 41 the library in two modes, either its own variadic data functionality or deferring 42 to the implementation of variadic macros in the Boost PP library. 43 </p> 44<p> 45 Once support for variadic data had been added to Boost PP I stripped down the 46 functionality of this library to only include variadic macro support for functionality 47 which was an adjunct to the support in Boost PP. This functionality might be 48 seen as experimental, since it largely relied on a macro which tested for empty 49 input which Paul Mensonides, the author of Boost PP, had published on the Internet, 50 and which by the very nature of the C++ preprocessor is slightly flawed but 51 which was the closest approximation of such functionality which I believed 52 could be made. I had to tweak this macro somewhat for the Visual C++ preprocessor, 53 whose conformance to the C++ standard for macro processing is notably incorrect 54 in a number of areas. But I still felt this functionality could be used in 55 select situations and might be useful to others. Using this functionality I 56 was able to build up some other macros which tested for the various Boost PP 57 data types. I also was able to add in functionality, based on Paul Mendsonides 58 excellent work, for handling tuples in preprocessing data. 59 </p> 60<p> 61 All of this particular functionality is impossible to do effectively without 62 the use of variadic macros. But I had kept these features at a minimum because 63 of the difficulty of using variadic macros with compilers, most notably Visual 64 C++, whose implementation of variadic macros is substandard and therefore very 65 difficult to get to work correctly when variadic macros must be used. 66 </p> 67<p> 68 I then realized that if I am going to have a library which takes advantage 69 of variadic macros I should see what I could do in the area of parsing preprocessor 70 data. This has led to a reorganization of the library as a set of macros largely 71 for parsing preprocessor data. All of this is now built on top of my use of 72 the almost perfect checking for emptiness which Paul Mensonides originally 73 created. 74 </p> 75</div> 76<table xmlns:rev="http://www.cs.rpi.edu/~gregod/boost/tools/doc/revision" width="100%"><tr> 77<td align="left"></td> 78<td align="right"><div class="copyright-footer">Copyright © 2010-2017 Tropic Software 79 East Inc</div></td> 80</tr></table> 81<hr> 82<div class="spirit-nav"> 83<a accesskey="p" href="../BOOST_VMD_IS_VMD_TUPLE.html"><img src="../../../../../doc/src/images/prev.png" alt="Prev"></a><a accesskey="u" href="../index.html"><img src="../../../../../doc/src/images/up.png" alt="Up"></a><a accesskey="h" href="../index.html"><img src="../../../../../doc/src/images/home.png" alt="Home"></a><a accesskey="n" href="vmd_compilers.html"><img src="../../../../../doc/src/images/next.png" alt="Next"></a> 84</div> 85</body> 86</html> 87