Remove dependency to CPP: support for #define macros
commitaaa4517df792f55a23ef1566a9808581822fb9d6
authorChristophe CURIS <christophe.curis@free.fr>
Fri, 22 Jun 2012 22:25:38 +0000 (23 00:25 +0200)
committerCarlos R. Mafra <crmafra@gmail.com>
Sat, 14 Jul 2012 18:22:20 +0000 (14 20:22 +0200)
treed4a82516d5667df670492266a29859d89765ab22
parent88a82ab8df5339665008643bc41475620434e413
Remove dependency to CPP: support for #define macros

This adds support for defining new macros, with or without parameters, which
when found afterwards in the text are replaced by their definition.
The complex analysis for arguments replacement is done at macro definition
time, so it is done only once and the macro expansion will be fast.
The macro-related functions have been placed in their own file because it is
quite a complex task and we do not want filesize to explode, it is always
better to keep things human-sized.
WINGs/Makefile.am
WINGs/menuparser.c
WINGs/menuparser.h
WINGs/menuparser_macros.c [new file with mode: 0644]