Commit 2413cb57 authored by Nobuaki Sukegawa's avatar Nobuaki Sukegawa
Browse files

Make C++ string oneof field compatible with C++11

string oneof field was generated into "const ArenaStringPtr" field inside
"default_oneof_instance_" struct (of name "<class name>OneofInstance").

On the other hand, in C++11, const field of type with trivial default
constructor causes enclosing type's implicit default constructor to be deleted.

Since ArenaStringPtr has tirvial default constructor, this caused default
constructor of "default_oneof_instance_" struct to be deleted, making the
constructor call inside generated code invalid and fail to compile.
parent 4470dcba
Loading
Loading
Loading
Loading
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please to comment