I have three header files one containing the following
pre-processor directives:
#ifdef __STDC__
#include <headerA.h>
#else
#include <headerB.h>
#endif
The other two:
headerA.h: contains function prototypes with parameters ie:
int myfunc(int p1,char *p2);
headerB.h: contains function prototypes with no parameters ie:
int myfunc(/*int p1,char *p2*/);
When I compile my program using MS Visual C++ 5.0, <headerB.h>
is included. I would like to have <headerA.h> included instead.
What do I need to set to make sure __STDC__ is set appropriately,
ie to include <headerA.h>?
Also what does __STDC__ actually mean to the compiler?
BTW: The actual header files that I am having trouble with
are from Oracle 8.03 OCI in "oci.h":
#ifdef __STDC__
#include <ociapr.h> // I think the 'a' stands for Ansi
#include <ociap.h>
#else
#include <ocikpr.h> // I think the 'k' stands for Kernighan
#include <ocikp.h>
#endif
1. Make sure the source file that includes the header file has a .c extension.
2. Disable language extensions in the C/C++ tab of the Project Settings dialog.