Tree depth

The changes in this file are really necessary?