www.digitalmars.com         C & C++   DMDScript  

c++ - # line directives

reply Josh Rendlesham <Josh_member pathlink.com> writes:


For example, the line:



gives an "identifier expected" error. Once that line is removed, however, the
file compiles fine. 

Is there an option to allow for the compilation of such constructs (in my case
in the C output from an Objective-C preprocessor)?

Thanks,
Josh Rendlesham
Jun 14 2003
parent reply "Walter" <walter digitalmars.com> writes:
"Josh Rendlesham" <Josh_member pathlink.com> wrote in message
news:bcgp55$1m5f$1 digitaldaemon.com...

directives?
 For example, the line:



 gives an "identifier expected" error. Once that line is removed, however,
the
 file compiles fine.
I think that's invalid C code.
 Is there an option to allow for the compilation of such constructs (in my
case
 in the C output from an Objective-C preprocessor)?
Probably the easiest way to deal with it is to run a global search/replace
Jun 17 2003
parent Josh Rendlesham <rendlesham fastmail.fm> writes:
Thanks for the reply.


it being noted in the GCC CPP docs that they support it mainly for
compatibility with older C code. 

Like you suggested, replacing all instances does seem to work quite well.

  Josh


Walter wrote:

 
 "Josh Rendlesham" <Josh_member pathlink.com> wrote in message
 news:bcgp55$1m5f$1 digitaldaemon.com...

directives?
 For example, the line:



 gives an "identifier expected" error. Once that line is removed, however,
the
 file compiles fine.
I think that's invalid C code.
 Is there an option to allow for the compilation of such constructs (in my
case
 in the C output from an Objective-C preprocessor)?
Probably the easiest way to deal with it is to run a global search/replace
Jun 17 2003