Hello,
I have a project that I was working on about 6 months ago and was looking to return to since I have an increase of free time. After re-installing Qt and my C++ environment, I tried to run my code and I was met with one error (repeated ~200 times)
D:\Code\Github\D2GUI\model\triggers\dguistructurev alue.h:16: error: C4430: missing type specifier - int assumed. Note: C++ does not support default-int
D:\Code\Github\D2GUI\model\triggers\dguistructurev alue.h:16: warning: C4183: 'append': missing return type; assumed to be a member function returning 'int'
I spent quite a while google searching and the only case I've seen this error come up is if the type that a function returns does not exist/has not been declared yet (circular dependency style issues)
An example of the code that produces this error is this
#ifndef DGUIREADER_H
#define DGUIREADER_H
#include <QString>
#include "model/triggers/dguifile.h"
class DGUIReader
{
public:
DGUIReader();
WriteFile(DGUIFile *);
};
#endif // DGUIREADER_H
#ifndef DGUIREADER_H
#define DGUIREADER_H
#include <QString>
#include "model/triggers/dguifile.h"
class DGUIReader
{
public:
DGUIReader();
DGUIFile OpenFile(QString *);
WriteFile(DGUIFile *);
};
#endif // DGUIREADER_H
To copy to clipboard, switch view to plain text mode
The error is pointing to this line
WriteFile(DGUIFile *);
WriteFile(DGUIFile *);
To copy to clipboard, switch view to plain text mode
My only guess is that the error is because I didn't define the return type, but
- This is the way my code was running previously and it worked perfectly fine
- I made a new project using this same style of ignoring the return type to assume int and it worked perfectly fine
I was wondering if there was some Qt configuration option I messed up for this project or something... I would go through and convert every function to "void WriteFile(..." but considering that this error should not show up I'd rather try to resolve it if it is easily resolvable or if there is another underlying problem with my Qt configuration
Thanks, ~Arhowk
Bookmarks