enh/brk: added code to repeat a pattern