summaryrefslogtreecommitdiff
path: root/test/ARCMT
diff options
context:
space:
mode:
authorArgyrios Kyrtzidis <akyrtzi@gmail.com>2017-04-28 00:25:06 +0000
committerArgyrios Kyrtzidis <akyrtzi@gmail.com>2017-04-28 00:25:06 +0000
commit232bf3f19ad64866774ba4d448ae07f555f133d8 (patch)
tree820ea3a8565093002ed9d1d17547c6417defd5b1 /test/ARCMT
parent118b5946cfd942bd239465e4662387947320861f (diff)
[ARCMigrate] When applying changes from remap files, disable the 'adjustRemovals' functionality of EditedSource
'adjustRemovals' is used to avoid situation when removing a range inadvertently causes 2 separate identifiers to get joined into one. But it is not useful when the edits are character precise, as is the case with the remap files. git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@301602 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'test/ARCMT')
-rw-r--r--test/ARCMT/remap-applying.c4
-rw-r--r--test/ARCMT/remap-applying.c.result4
2 files changed, 8 insertions, 0 deletions
diff --git a/test/ARCMT/remap-applying.c b/test/ARCMT/remap-applying.c
new file mode 100644
index 0000000000..b6280bf938
--- /dev/null
+++ b/test/ARCMT/remap-applying.c
@@ -0,0 +1,4 @@
+a bc
+
+// RUN: echo "[{\"file\": \"%s\", \"offset\": 1, \"remove\": 2, }]" > %t.remap
+// RUN: c-arcmt-test %t.remap | arcmt-test -verify-transformed-files %s.result
diff --git a/test/ARCMT/remap-applying.c.result b/test/ARCMT/remap-applying.c.result
new file mode 100644
index 0000000000..975dc9e431
--- /dev/null
+++ b/test/ARCMT/remap-applying.c.result
@@ -0,0 +1,4 @@
+ac
+
+// RUN: echo "[{\"file\": \"%s\", \"offset\": 1, \"remove\": 2, }]" > %t.remap
+// RUN: c-arcmt-test %t.remap | arcmt-test -verify-transformed-files %s.result