diff options
author | Jisi Liu <jisi.liu@gmail.com> | 2017-08-03 11:13:25 -0700 |
---|---|---|
committer | Jisi Liu <jisi.liu@gmail.com> | 2017-08-03 11:13:25 -0700 |
commit | 4cbbf33b773fb95aa339ee50517fd375f5120ffe (patch) | |
tree | 7b747f7af11853481922d327fc15de93f6d9b154 /src/google/protobuf/any.pb.cc | |
parent | 778178479626b0e5b4de0701103a1bb0a067702d (diff) | |
download | protobuf-4cbbf33b773fb95aa339ee50517fd375f5120ffe.tar.gz protobuf-4cbbf33b773fb95aa339ee50517fd375f5120ffe.tar.bz2 protobuf-4cbbf33b773fb95aa339ee50517fd375f5120ffe.zip |
Fix invalid offsetof warning.
Use composition instead of inheritance for oneof default.
Diffstat (limited to 'src/google/protobuf/any.pb.cc')
-rw-r--r-- | src/google/protobuf/any.pb.cc | 7 |
1 files changed, 5 insertions, 2 deletions
diff --git a/src/google/protobuf/any.pb.cc b/src/google/protobuf/any.pb.cc index 1bd6cbe2..ace79986 100644 --- a/src/google/protobuf/any.pb.cc +++ b/src/google/protobuf/any.pb.cc @@ -19,7 +19,10 @@ namespace google { namespace protobuf { -class AnyDefaultTypeInternal : public ::google::protobuf::internal::ExplicitlyConstructed<Any> { +class AnyDefaultTypeInternal { +public: + ::google::protobuf::internal::ExplicitlyConstructed<Any> + _instance; } _Any_default_instance_; namespace protobuf_google_2fprotobuf_2fany_2eproto { @@ -88,7 +91,7 @@ void TableStruct::InitDefaultsImpl() { GOOGLE_PROTOBUF_VERIFY_VERSION; ::google::protobuf::internal::InitProtobufDefaults(); - _Any_default_instance_.DefaultConstruct(); + _Any_default_instance_._instance.DefaultConstruct(); ::google::protobuf::internal::OnShutdownDestroyMessage( &_Any_default_instance_);} |