Add checking circular reference