• 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
benchmarks Loading commit data...
cmake Loading commit data...
conformance Loading commit data...
csharp Loading commit data...
editors Loading commit data...
examples Loading commit data...
java Loading commit data...
javanano Loading commit data...
m4 Loading commit data...
more_tests Loading commit data...
objectivec Loading commit data...
protoc-artifacts Loading commit data...
python Loading commit data...
ruby Loading commit data...
src Loading commit data...
.gitignore Loading commit data...
.travis.yml Loading commit data...
BUILD Loading commit data...
CHANGES.txt Loading commit data...
CONTRIBUTORS.txt Loading commit data...
INSTALL.txt Loading commit data...
LICENSE Loading commit data...
Makefile.am Loading commit data...
Protobuf.podspec Loading commit data...
README.md Loading commit data...
WORKSPACE Loading commit data...
appveyor.bat Loading commit data...
appveyor.yml Loading commit data...
autogen.sh Loading commit data...
configure.ac Loading commit data...
generate_descriptor_proto.sh Loading commit data...
gmock.BUILD Loading commit data...
post_process_dist.sh Loading commit data...
protobuf-lite.pc.in Loading commit data...
protobuf.pc.in Loading commit data...
travis.sh Loading commit data...
update_file_lists.sh Loading commit data...