If you look at the code, you will see that it is not correct to count the number of calls to free_expr itself, because free_expr does not always call free.