fixed bug in edit_line_r.py: now incorporates the case of multilple punctuations