transform: fix replacement of particular pattern instance
commit193eb8f81d8fbf7b1f3bd2b93f60882e56325d72
authorSergey Poznyakoff <gray@gnu.org>
Sat, 28 Aug 2021 06:13:05 +0000 (28 09:13 +0300)
committerSergey Poznyakoff <gray@gnu.org>
Sat, 28 Aug 2021 06:57:26 +0000 (28 09:57 +0300)
treefda45c8c526ad7d513a8138b1c0445f5a258255e
parent93082d6eb84a086b02c7a8607f2553d5d9d0a93c
transform: fix replacement of particular pattern instance

This fixes handling of expressions like 's/s/@/2'

Fix suggested by Anthony Heading.

* src/transform.c (_single_transform_name_to_obstack): Avoid duplicating
initial prefix if replace is not needed.
src/transform.c