this is not what i am asking:
the reason for this is to make the code easier to maintain (e.g. if the included string is long or easier to maintain by a non-programmer).
in python, for example, I would write something like:
regstr1 = 'dogs|cats|mice' regstr_container = '^animal: (cows|sheep|%s|zebra)$' % regstr1 re.compile(regstr_container)
re = /^animal: (rami|shmulik|dudu)$/;
or am I missing something?
source to share