Related questions
Base class undefined
My code below generates the error
'WorldObject': [Base class undefined (translated from german)]
Why is this? Here is the code which produces this error:
ProjectilObject.h:
#pragma once
#ifndef _PROJECTILOBJECT_H_
#define _PROJECTILOBJECT_H_
#include "GameObjects.h"
class WorldObject;
class …
Redefining vs. Overriding in C++
I am confused about the differences between redefining and overriding functions in derived classes.
I know that - In C++, redefined functions are statically bound and overridden functions are dynamically bound and that a a virtual function is overridden, and …
c++ abstract base class private members
Just wanted some clarification.
Should abstract base classes never have private members? For example
class abc{
public:
virtual void foo()=0;
private:
int myInt;
}
you can never access myInt since you cannot create an instance of abc and it will not …