prog.cpp:18:29: error: use of undeclared identifier 'A'
std::vector<std::shared_ptr<A>> items;
^
prog.cpp:18:38: error: expected a type
std::vector<std::shared_ptr<A>> items;
^
prog.cpp:20:11: error: unknown type name 'A'
void test(A& a) {
^
prog.cpp:24:27: error: use of undeclared identifier 'B'
void test(std::shared_ptr<B> b) {
^
prog.cpp:24:27: error: use of undeclared identifier 'B'
prog.cpp:28:11: error: unknown type name 'C'
void test(C& c) {
^
prog.cpp:33:2: error: use of undeclared identifier 'items'
items.push_back(std::make_shared<B>());
^
prog.cpp:33:35: error: use of undeclared identifier 'B'
items.push_back(std::make_shared<B>());
^
prog.cpp:34:14: error: use of undeclared identifier 'items'
for(auto i: items) {
^
9 errors generated.