diff options
author | Peter Kasting <pkasting@google.com> | 2015-08-27 20:16:33 -0700 |
---|---|---|
committer | Peter Kasting <pkasting@google.com> | 2015-08-27 20:16:33 -0700 |
commit | 4f3bead5373decc3750f65ff35ca8785fa97ba38 (patch) | |
tree | 02fd60c302a79cec83caa5b2e93b88c2d75b2623 /csharp/buildall.sh | |
parent | 47210ccd77c88becb9097d59b7765c2d2b41d68e (diff) | |
download | protobuf-4f3bead5373decc3750f65ff35ca8785fa97ba38.tar.gz protobuf-4f3bead5373decc3750f65ff35ca8785fa97ba38.tar.bz2 protobuf-4f3bead5373decc3750f65ff35ca8785fa97ba38.zip |
Remove a static initializer by removing a global of non-POD type.
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.
Diffstat (limited to 'csharp/buildall.sh')
0 files changed, 0 insertions, 0 deletions