I'm just trying to run the program, but I get this errror with respect to the class:
:-1: error: collect2: ld returned 1 exit status
I only get this error when I do T : public QObject
(Adding QObject)
Help would be appreciated! Thanks
#ifndef T_H
#define T_H
#include <QString>
#include <QObject>
{
public:
T() {}
};
#endif // T_H
#ifndef T_H
#define T_H
#include <QString>
#include <QObject>
class T : public QObject
{
public:
T() {}
};
#endif // T_H
To copy to clipboard, switch view to plain text mode
#include <QtCore/QCoreApplication>
#include <QtDebug>
#include <QString>
#include "T.h"
int main(int argc, char *argv[])
{
T ok();
qDebug() << "ok";
return aa.exec();
}
#include <QtCore/QCoreApplication>
#include <QtDebug>
#include <QString>
#include "T.h"
int main(int argc, char *argv[])
{
QCoreApplication aa(argc, argv);
T ok();
qDebug() << "ok";
return aa.exec();
}
To copy to clipboard, switch view to plain text mode
Bookmarks