BUG: allow tuples in recursive call to replace

This avoids the seeming passage of regular expressions

closes #5143.