render_name: handle escapes in patterns