This will also happen if you’ve forgotten to specify public inheritance on the derived class, i.e. if like me you write this:
class Derived : Base
{
};
Instead of:
class Derived : public Base
{
};
More Related Contents:
- std::shared_ptr initialization: make_shared() vs shared_ptr(new Foo) [duplicate]
- Where is shared_ptr?
- Why would I std::move an std::shared_ptr?
- What is a smart pointer and when should I use one?
- How do I call ::std::make_shared on a class with only protected or private constructors?
- Why can I not push_back a unique_ptr into a vector?
- shared_ptr to an array : should it be used?
- Difference in make_shared and normal shared_ptr in C++
- Differences between std::make_unique and std::unique_ptr with new
- Differences between unique_ptr and shared_ptr [duplicate]
- “Downcasting” unique_ptr to unique_ptr
- Why isn’t there a std::shared_ptr specialisation?
- Why do std::shared_ptr work
- Should we pass a shared_ptr by reference or by value?
- How much is the overhead of smart pointers compared to normal pointers in C++?
- Is there a non-atomic equivalent of std::shared_ptr? And why isn’t there one in ?
- smart pointers and arrays
- Passing shared pointers as arguments
- How to avoid memory leak with shared_ptr?
- std::shared_ptr thread safety explained
- Should I use shared_ptr or unique_ptr
- How do shared pointers work?
- Understanding gsl::narrow implementation
- unique_ptr and OpenSSL’s STACK_OF(X509)*
- shared_ptr and weak_ptr differences
- Example to use shared_ptr?
- Why does unique_ptr take two template parameters when shared_ptr only takes one?
- C++11: Replace all non-owning raw pointers with std::shared_ptr()?
- weak_ptr, make_shared and memory deallocation
- Does C++11 unique_ptr and shared_ptr able to convert to each other’s type?