Example static locals workaround

Re: previously Happily, MSVC 2013 is going to support static initialization of locally scoped variables. In the meanwhile, you can work around this shocking deficiency most of the time, by doing the compiler’s work manually via double-checked locking & taking advantage of BSS zero initialization. Here’s a convenience macro that defines and initializes a locally scoped static safely in MSVC 2012 and prior: Note that for this to work, the type must have a trivial constructor, or it’s turtles all the way down. Thanks to Andrew Gaul for suggesting some some cleanups over a previous iteration of this code.