Ok, some more info.. thanks to your help

So I renamed Arc to ArcShape in the protofile, for example, and it all
works fine.
Funny thing is, if I rename Square to Polyline, I get the same
errors.

If I rename Polyline to PolyLine.. all is ok.

Using Ellipse throws errors also...

So, I guess I cant pin down exactly where the conflict is, but there
must be some geometry objects included with the c++ console project
type i created...

thanks!

On Dec 10, 4:36 pm, Kenton Varda <ken...@google.com> wrote:
> The errors suggest to me that somewhere you have #defined Arc as a macro.
>  Is this possible?
>
>
>
> On Thu, Dec 10, 2009 at 9:21 AM, bayWeiss <bzwr...@yahoo.com> wrote:
> > I cant post the whole generated .h file, but below is a snippet where
> > for some reason the compiler cant identify the Arc class. The
> > declaration for Arc is definitely above the below c++ snippet, but it
> > acts as if it cant recognize it.
>
> > ---the errors are from VS2008------------------------------
>
> > error C4430: missing type specifier - int assumed. Note: C++ does not
> > support default-int     c:\googleprototest\googleprototestcppserver
> > \person.pb.h    669     GoogleProtoTestCPPServer
> > error C2143: syntax error : missing ';' before '&'      c:\googleprototest
> > \googleprototestcppserver\person.pb.h   669
> > error C2838: 'Arc' : illegal qualified name in member declaration       c:
> > \googleprototest\googleprototestcppserver\person.pb.h   669
> > error C4430: missing type specifier - int assumed. Note: C++ does not
> > support default-int     c:\googleprototest\googleprototestcppserver
> > \person.pb.h    669
>
> > -----here is the generated header snippet from 2.2.0a protoc, within
> > the Entity class declaration--------
>
> >  // optional .Square square = 3;
> >  inline bool has_square() const;
> >  inline void clear_square();
> >  static const int kSquareFieldNumber = 3;
> >  inline const ::Square& square() const;
> >  inline ::Square* mutable_square();
>
> >  // optional .Arc arc = 4;
> >  inline bool has_arc() const;
> >  inline void clear_arc();
> >  static const int kArcFieldNumber = 4;
> >  inline const ::Arc& arc() const;                         // <- the
> > problem is here, line 669
> >  inline ::Arc* mutable_arc();                               // and
> > here as well
>
> > -------here is the .proto file---------
>
> > message Point
> > {
> >        required double X = 1;
> >        required double Y = 2;
> > }
>
> > message Circle
> > {
> >        required Point point1 = 1;
> >        required Point point2 = 2;
> >        required Point point3 = 3;
> >        required Point point4 = 4;
> > }
>
> > message Square
> > {
> >        repeated Point pointList = 1;
> > }
>
> > message Arc
> > {
> >        required Point center = 1;
> >        required double startAngle = 2;
> >        required double endAngle = 3;
> > }
>
> > message Parameter
> > {
> >        required double somethingHere = 1;
> > }
>
> > message Entity
> > {
> >        enum Type { CIRCLE = 1; SQUARE = 2; ARC = 3; }
>
> >        // Identifies which entity it is.
> >        required Type type = 1;
>
> >        optional Circle circle = 2;
> >        optional Square square = 3;
> >        optional Arc arc = 4;
> > }
>
> > message Job
> > {
> >        repeated Entity entity = 1;
> > }
>
> > message Initialize
> > {
> > }
>
> > message Start
> > {
> > }
>
> > message MainMessage
> > {
> >        enum Type { NEW_JOB = 1; INITIALIZE = 2; START = 3;}
>
> >        // Identifies which field is filled in.
> >        required Type type = 1;
>
> >        // One of the following will be filled in.
> >        optional Job job = 2;
> >        optional Initialize initialize = 3;
> >        optional Start start = 4;
> > }
>
> > --
>
> > You received this message because you are subscribed to the Google Groups
> > "Protocol Buffers" group.
> > To post to this group, send email to proto...@googlegroups.com.
> > To unsubscribe from this group, send email to
> > protobuf+unsubscr...@googlegroups.com<protobuf%2bunsubscr...@googlegroups.c­om>
> > .
> > For more options, visit this group at
> >http://groups.google.com/group/protobuf?hl=en.- Hide quoted text -
>
> - Show quoted text -

--

You received this message because you are subscribed to the Google Groups 
"Protocol Buffers" group.
To post to this group, send email to proto...@googlegroups.com.
To unsubscribe from this group, send email to 
protobuf+unsubscr...@googlegroups.com.
For more options, visit this group at 
http://groups.google.com/group/protobuf?hl=en.


Reply via email to