I'm creating a simple vector class in C++ using dynamic arrays. The constructor with an int
parameter must be deleted.
I have two errors:
Deleted definition of
simple_vector::simple_vector(int)
from my cpp file.Previous declaration of
simple_vector::simple_vector(int)
from my hpp file.
What's going on? The name of my class is simple_vector
. It can only contain double
elements.
Honestly, I have no idea what to do.
Hpp file
simple_vector(const int a);
Cpp file
simple_vector::simple_vector(const int a) = delete;