[antlr-interest] C++ compile issue with ANTLR 3.1.0b1 C runtime files

Jim Idle jimi at temporal-wave.com
Thu Mar 13 10:50:46 PDT 2008


Also,

 

Try #include "Winsock_2.h" as well, though you should not really need to include this I think. Perhaps there is some configuration you can end up with whereby you do need this. If that works for you, I will add it to the include files perhaps.

 

Jim

 

From: antlr-interest-bounces at antlr.org [mailto:antlr-interest-bounces at antlr.org] On Behalf Of Chris Snyder
Sent: Thursday, March 13, 2008 10:13 AM
To: antlr-interest at antlr.org
Subject: [antlr-interest] C++ compile issue with ANTLR 3.1.0b1 C runtime files

 

I'm trying to compile my C output in CPP and I get this error

 

libantlr3c-3.1.0b1\include\antlr3debugeventlistener.h(42) : error C2146: syntax error : missing ';' before identifier 'socket'

 

which corresponds to this:

 

antlr3debugeventlistener.h

/// The socket structure we receive after a successful accept on the serverSocket

///

SOCKET                        socket;

 

I looked for the SOCKET definition and didn't find one being used in my configuration. I did find a UNIX definition in antlr3defs.h:

 

// SOCKET not defined on Unix

// 

typedef     int                     SOCKET;

 

but it is not even reached because preprocessor ANTLR3_WINDOWS is defined 

 

Should I be including a windows socket header?

 

I'm in windows XP using VS2005 and VC++ 2005.

 

Thanks,

Chris

 

 

T-VEC Technologies, Inc.

 



-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://www.antlr.org/pipermail/antlr-interest/attachments/20080313/b8cee569/attachment.html 


More information about the antlr-interest mailing list