I was messing around in Visual Studio and tried this modification:
google::protobuf::Closure* closure =
google::protobuf::NewCallback(&ct,
&ClosureTest::MethodWithArg, &dr);
and it worked. Is explicitly specifying the template parameters the
preferred solution?
On Aug 30, 11:29 pm, srlindemann
The problem is that the parameter binding that you are providing has type
DummyResponse* but the method you are trying to bind takes const
DummyResponse*. Even though the former is implicitly convertible to the
latter, the compiler will not consider this when selecting a template
overload. The so
C++ Protocol Buffers use UTF-8 for all text encoding, regardless of
platform. If you want to use some other encoding in your code, you will
have to manually convert between that and UTF-8 when interacting with
Protocol Buffers.
In Java and Python everything is taken care of automatically, since th
That makes perfect sense---thanks.
On Mon, Aug 31, 2009 at 12:36 PM, Kenton Varda wrote:
> The problem is that the parameter binding that you are providing has type
> DummyResponse* but the method you are trying to bind takes const
> DummyResponse*. Even though the former is implicitly converti
Thanks for fixing the docs, Henner.
On Sat, Aug 29, 2009 at 6:59 PM, Henner Zeller wrote:
> And yeah, documentation needs to be fixed.
>
> On Aug 28, 2009 1:35 PM, "Omnifarious" wrote:
>
>
> An example from
> http://code.google.com/apis/protocolbuffers/docs/proto.html
> produces an error when
I just installed Snow Leopard, which ships with:
$ gcc --version
i686-apple-darwin10-gcc-4.2.1 (GCC) 4.2.1 (Apple Inc. build 5646)
Copyright (C) 2007 Free Software Foundation, Inc.
This is free software; see the source for copying conditions. There
is NO
warranty; not even for MERCHANTABILITY or
What compiler flags are you using? Since you were able to compile
libprotobuf itself, I assume you have turned on additional warnings for your
own project?
On Mon, Aug 31, 2009 at 3:26 PM, Joshua Haberman wrote:
>
> I just installed Snow Leopard, which ships with:
>
> $ gcc --version
> i686-appl
Good point, this was with -Wextra (which I had forgotten I compile
with). I can understand if you're not interested in accommodating
this. It is strange that -Wextra warns about this for this particular
gcc version, but not others that I've tried.
On Aug 31, 4:49 pm, Kenton Varda wrote:
> What
Joshua Haberman writes:
> The protobuf library compiled and installed fine, but the generated
> classes threw warnings (and since I was compiling with -Werror, failed
> to compile). The warning was:
>
> benchmarks/google_messages.pb.cc: In copy constructor
> ‘benchmarks::SpeedMessage2::SpeedMes
On Aug 31, 5:17 pm, Michael Poole wrote:
> Joshua Haberman writes:
> > The protobuf library compiled and installed fine, but the generated
> > classes threw warnings (and since I was compiling with -Werror, failed
> > to compile). The warning was:
>
> > benchmarks/google_messages.pb.cc: In co
I'm OK with a patch that just adds the call to Message().
I'm not OK with a patch that explicitly initializes every single field,
which is what Michael is talking about, since it conflicts with an
optimization we did to reduce code size. I'd also rather not add an option
for this because it would
11 matches
Mail list logo