Oracle FAQ | Your Portal to the Oracle Knowledge Grid |
![]() |
![]() |
Home -> Community -> Usenet -> c.d.o.misc -> Syntax error in .pc file (pointer)
I am getting a precompilation error using Pro*C/C++. It does not seem to
like my pointers. here is the source where the errors occur:
This is the .h file:
struct Class_type {
char Name[Class_Name_Length]; int Fields; char Parent[Class_Name_Length]; char Description[Class_Description_Length]; int Level; };
and here is the source .c:
List_ptr DB_GetTableNames (
List_ptr ClassNames, char *ErrorMessage) { Class_ptr Class; List_ptr ClassAttributes; Attribute_ptr ClassAttribute; List_ptr TableNames; char *TableName; char *TempTableName; int ListTableCount;
TableNames = Create_List ();
/* Retrieve all attributes for the class, including parent attributes */
Reset_List_Iterator (ClassNames);
Class = (Class_ptr)Next_List_Element (ClassNames);
ClassAttributes = DB_GetClassAttributes (Class->Name, ErrorMessage);
if (ErrorMessage[0] != 0) return (Create_List ());
/* Retrieve the Class Table Names */
Reset_List_Iterator (ClassNames);
while (!Is_End_Of_List (ClassNames)) {
Class = (Class_ptr)Next_List_Element (ClassNames); TempTableName = ConvertToValidDBName (Class->Name); TableName = (char*) malloc(sizeof(strlen(TempTableName) + 1)); TableName[0] = 0; strcpy (TableName, TempTableName); Enqueue ((Element_type)TableName, TableNames); }
it doesn't like "Class = (Class_ptr)Next_List_Element (ClassNames);" I can't understand why?
Are there some flags that may affect the typechecking that I am not aware of?
Here are my precompile flags:
PROFLAGS = include=$(ORACLEINCLUDE) include=$(INCDIR)
And here is the portion of my makefile to execute the precompiler:
/usr/oracle1/app/oracle/product/7.3.2.2/bin/proc $(PROFLAGS) iname=$< Received on Fri Aug 14 1998 - 15:47:01 CDT
![]() |
![]() |