C2055 error - expected formal parameter list, not a type list

c, compiler-errors

Solution

When you get a truly weird compiler error, look at the preceding line.

In this case (ignoring whitespace and preprocessor directives), it's this, from the header file.

int new_alreadyThere(sWord*, char*)

You're missing a semicolon at the end of it.

Problem

I keep getting this error: C2055 error - expected formal parameter list, not a type list I know what it means; I read about it on the Internet, yet I don't understand why I keep getting it. The part of my code that triggers the error (the file is called `other_funcs.c`): ``` #include "main_funcs.h" #include "other_funcs.h" void addWord(sWord **first) //line #4 { sWord *after; char *input_string, *part; const char seperator[4] = "_#_"; /.......bla bla.... more code.../ ``` `sWord` is a `struct`. The error is: ``` 1>d:\cs - exercises\ex5\backup\new folder\other_funcs.c(4): error C2055: expected formal parameter list, not a type list ``` I don't know if this is necessary, but the header file with the the `addWord()` function is called `other_funcs.h`: ``` #ifndef OTHER_FUNCS_H #define OTHER_FUNCS_H void addWord(sWord**); char *inputString(); int badInput(char*); void removeWord(sWord**); int checkYear(sWord*, unsigned short); int my_strlen(char*); int countDist(char*, char*); int new_alreadyThere(sWord*, char*) #endif ```

Original source