The main reason google::protobuf::Arena::CreateMessage failed at compilation was because i was using parameters wrong. Can i create message array using CreateArray? If not then can i create message array using arena?
Friday, March 13, 2020 at 5:50:59 PM UTC+3, Atılhan Emre Dursunoğlu wrote: > **What version of protobuf and what language are you using?** > Version: v3.11.4 > Language: C++ > > **What operating system (Linux, Windows, ...) and version?** > Linux 5.4.23-1-MANJARO > **What runtime / compiler are you using (e.g., python version or gcc > version)** > both gcc 9.2.1 and clang 9.0.1 > > When I try to create new message via arena functions, compilation fails. > If I use google::protobuf::Arena::CreateArray it fails because of > static_assertion (error: static assertion failed: CreateArray requires a > trivially destructible type). For google::protobuf::Arena::CreateMessage, I > get "error: no matching function for call to ‘foo::Foo::Foo(std::nullptr_t, > int)’". > > Here is a mock project. > https://github.com/Thelta/protobuf_mock > > Thanks. > -- You received this message because you are subscribed to the Google Groups "Protocol Buffers" group. To unsubscribe from this group and stop receiving emails from it, send an email to [email protected]. To view this discussion on the web visit https://groups.google.com/d/msgid/protobuf/b490a0b9-6719-4d63-99cd-9b05dadf9874%40googlegroups.com.
