• Peter Kasting's avatar
    Remove a static initializer by removing a global of non-POD type. · 4f3bead5
    Peter Kasting authored
    These are banned by the Google style guide, and Chromium has a hard
    no-new-static-initializers policy preventing updating to a new version of
    libprotobuf unless this is resolved.  This is the first such change, I'll need
    to make at least one more in the future.
    
    Luckily, the protobuf source tree already has an alternative to static
    initializers in once.h; use that machinery instead.
    
    I defined everything in the .cc file in a blob to replace the old implementation
    rather than matching the .h layout precisely; let me know if a different
    ordering is preferred.  I also eliminated the macro that used to be used here as
    spelling everything out only takes one additional line, and the macro didn't
    actually handle all details of using a particular member variable, just the
    declaration, so it felt a bit error-prone.
    4f3bead5
Name
Last commit
Last update
..
google/protobuf Loading commit data...
solaris Loading commit data...
Makefile.am Loading commit data...