Qt: field has incomplete type

In my experience, when such weird errors like this appeared with no reason, most of the time it has been solved by changing some names, hence it was a name conflict. (but most of the time, I still didn't understand where was the conflict).

So I would desperately try to change the names of, in order:

  1. the name header protection PROCESS_H
  2. the name of the class Process
  3. the name of the member filename
  4. the name of the files process.h and process.cpp (if there are other folders with same file names, they will be compiled at the same place if you use qmake)
  5. the name of the member pid, because you are really desperate at this point

Use something you are really sure it can't be already used, like MySuperFancyProcess ;-)

Tags:

C++

Qt