Hi all,
I receive an error when compiling this. Cant understand why.
error: request for member 'toString' in 'shape; which is of non-class type of 'GeometricObject()' GeometricObject.h
#ifndef GEOMETRICOBJECT_H_INCLUDED
#define GEOMETRICOBJECT_H_INCLUDED
#include <string>
using namespace std;
class GeometricObject{
public:
GeometricObject();
GeometricObject(string colour, bool filled);
string toString();
When building a program you first have to compile all the source (.cpp) files to object files. Then you have to link all the object files together to create the executable file. You might be able to to it all in one step. How to do it depends on the compiler/IDE.