Jump to content
OMRON Forums

More preprocessing


daves
 Share

Recommended Posts

I am grateful you have implemented

 

#define
#ifdef
#else
#endif

 

Firstly I would also like to see

 

#if
#elif
defined

 

to complete the conditional preprocessing to a C level.

 

In particular I find I want to do things like:

 

#if defined BUFSIZE && BUFSIZE >= 1024
#endif
#if RIGNUMBER == 15 || RIGNUMBER == 14
#endif

 

Secondly I would like the conditional directives to work inside the pmh files, for example:

 

#define RIGHALF
//#define RIGFULL

#ifdef RIGHALF
global gFourWheelsTrue = 0;
#endif

#ifdef RIGFULL
global gFourWheelsTrue = 1;
#endif

 

This (only) warns of redefinition, i.e both lines are included after preprocessing.

Link to comment
Share on other sites

  • Replies 1
  • Created
  • Last Reply

Top Posters In This Topic

Top Posters In This Topic

Guest
This topic is now closed to further replies.
 Share


×
×
  • Create New...