Re: typedef error - please help



Ben wrote:
hi,

i'm converting an old VC 6 project to VC 2005.

it's giving this error:

error C2144: syntax error : 'char' should be preceded by ';'


this is in some header file of a class i have downloaded before to
handle smtp email... that line in that file is simply:

typedef char DwChar7; // type for ASCII characters


and there's no much code before it besides some #defines.... is there
something with typedef that causes this error ?

The line you cared to share with us has NO error. It's something beyond
that line that affects the overall compilation. See the previous line
and see if 'typedef' is not redefined as a macro somewhere (although it
would be illegal to redefine it).

V
--
Please remove capital 'A's when replying by e-mail
I do not respond to top-posted replies, please don't ask


.



Relevant Pages

  • typedef error - please help
    ... i'm converting an old VC 6 project to VC 2005. ... this is in some header file of a class i have downloaded before to ... handle smtp email... ... something with typedef that causes this error? ...
    (microsoft.public.vc.language)
  • Re: What this mean? Compiler output
    ... This probably means that you have multiple declaration of the ... And then a C source file includes both, the typedef for ccc will be ... any single header file more than once, ...
    (comp.lang.c)
  • Re-exporting functions from dynamically linked DLL
    ... I have a 3rd party DLL which does not include a LIB file, just a header file ... with typedef declarations for exported functions (It is intended for dynamic ... #define DllExport __declspec ... but I would prefer to just declare it as exported somehow. ...
    (microsoft.public.vc.mfc)
  • Re: Canonical format for header files (was... who cares?)
    ... > If you convert a C header file to a NASM include file, ... > much information that converting that file to anything else is ... That's why an intermediate canonical format is such a good idea. ... > But, I am a wizz at Basic, and Assembler. ...
    (alt.lang.asm)
  • Re: External structs - newbie question
    ... The header file for csd.c contains the typedef for a ... There is only one struct in use ... Declaring it in a header file is the right way to go. ... If you put the keyword extern before the declaration, it will not be a problem declaring it twice. ...
    (comp.lang.c)