Add debug output for TreeModel.