[Pyparsing] automatic naming of parse results?
Brought to you by:
ptmcg
From: <de...@de...> - 2008-04-03 17:26:31
|
Hi, is it possible to do sth. like .setResultsName globally and automatically? E.g.: a = pyparsing.Group(b + c) could work like: a = pyparsing.Group(b + c).setResultsName("a") if some flag is set or whatever. Reason: I don't like to add a lot of redundant code to my parser. Thanks in advance for any hint! |