tree.c (walk_tree): Expose tail recursion.
authorZack Weinberg <zack@wolery.cumb.org>
Wed, 6 Sep 2000 05:52:51 +0000 (05:52 +0000)
committerZack Weinberg <zack@gcc.gnu.org>
Wed, 6 Sep 2000 05:52:51 +0000 (05:52 +0000)
commit11f53b6a0879e853b8aa3e12b81b56f1582c38f6
tree70e50e84e9a226d6722859ba63eba0a30b37d9c9
parent3392dafcfdcbe74f8c60e14fa0f3ea73363552ab
tree.c (walk_tree): Expose tail recursion.

* tree.c (walk_tree): Expose tail recursion.
(walk_stmt_tree): New function.
* cp-tree.h: Prototype walk_stmt_tree.
* semantics.c (prune_unused_decls): Operate on SCOPE_STMTs not
the BLOCKs directly.  If a BLOCK has no variables after
pruning, discard it.
(finish_stmt_tree): Use walk_stmt_tree.  No need to save and
restore the line number.

From-SVN: r36178
gcc/cp/ChangeLog
gcc/cp/cp-tree.h
gcc/cp/semantics.c
gcc/cp/tree.c