Optimize m4_for.
commit8f5c14ff9143fb53a395f1a5fad9429a4feac26e
authorEric Blake <ebb9@byu.net>
Tue, 29 Jul 2008 18:21:25 +0000 (29 12:21 -0600)
committerEric Blake <ebb9@byu.net>
Wed, 30 Jul 2008 01:36:18 +0000 (29 19:36 -0600)
treec68398bdb27c2691d3422cab4118003e6a735ef4
parentc39d9a4678fe866ba77b8422292642f95ffbe41e
Optimize m4_for.

* lib/m4sugar/m4sugar.m4 (m4_for): Use fewer macros.
(_m4_for): Take additional parameter, for fewer m4_indir calls.
* lib/m4sugar/foreach.m4 (_m4_foreach, _m4_shiftn, m4_do)
(m4_reverse, _m4_list_pad, _m4_list_cmp): Adjust all callers.
* doc/autoconf.texi (Looping constructs) <m4_for>: Document subtle
semantic change caused by the optimization.
* tests/m4sugar.at (M4 loops): Test the new semantics.

Signed-off-by: Eric Blake <ebb9@byu.net>
ChangeLog
doc/autoconf.texi
lib/m4sugar/foreach.m4
lib/m4sugar/m4sugar.m4
tests/m4sugar.at