Relative Content

Tag Archive for c++chaining

Why this code work incorrect? What i do wrong?

Hello, please help me to undestand.
This code doesn’t work the way I think it should work.
What am I doing wrong? Add() method of A class return refference to newly created object in chlds vector. Then i call add() method on this newly created object, to add child to its cchlds vector array.