<p>These are just a couple of notes for some neat tips and tricks I’ve discovered over the years when using <a href="http://www.boost.org/doc/libs/1_56_0/libs/test/doc/html/index.html">Boost.Test</a>. They may not be all that useful to everybody else but they’re the ones I tend to forget about and then end up rediscovering. I’m using most of these with recent versions of Boost and these were tested with 1.54.</p>
<p>Quick hack/warning for those using an alternative command line processor like <a href="https://jpsoft.com/tccle-cmd-replacement.html">TCC</a> and also use Xoreax’ <a href="https://www.incredibuild.com/">Incredibuild</a> for distributed builds. Incredibuild is awesome, by the way, and if you have a larger C++ project that takes a long time to build, you should use it. And no, I’m not getting paid or receive free stuff for writing that.</p>
<p>As VS2012’s C++ compiler doesn’t support “true” variadic templates, the new runtime library classes that use variadic templates are implemented using macro magic behind the scenes. In order to get the “variadic” templates to accept more than the default of five parameters, you’ll have to set _VARIADIC_MAX to the desired maximum number of parameters (between five and ten).</p>
<p>I was profiling some code a while ago that makes extensive use of boost::variant and one of the lessons from the profiler run was that boost variants appear to be fairly expensive to construct and copy.</p>
<p>There, I’ve said it. No tiptoeing around.</p>
<p>Quick update to the previous post - it looks like at least some of the videos from GoingNative 2012 are now <a href="http://channel9.msdn.com/Events/GoingNative/GoingNative-2012">available on the Channel9 page</a>.</p>
<p>I had to reinstall VS2010 at work and because I clearly didn’t think this all the way through, forgot to save my autoexp.dat file before removing the old installation. And of course I didn’t realise what had happened until I had to dig deeper into some Qt GUI code that wasn’t quite working as expected, and of course I was prompted with the raw data.</p>
<p>Just came across a link to this link collection that I think will be useful to C++ programmers:</p>
<p>If you’re looking for a quick introduction to Boost.Test that covers the main features you’re likely to use, I would recommend looking at this blog post:</p>
<p>Yes, it’s one of those “note to self” posts, but I keep forgetting how to do it.</p>