summary refs log tree commit diff stats
path: root/tests/arc
diff options
context:
space:
mode:
authorAndreas Rumpf <rumpf_a@web.de>2022-09-12 00:58:29 +0200
committerGitHub <noreply@github.com>2022-09-12 00:58:29 +0200
commit6bf21e7b3dbf203baf23069c33bd79545681f466 (patch)
tree0fbc731c39b2e08772715ddf6e88458888f19fc6 /tests/arc
parent8850644cb750c3134f3ae2d54a5d76262888de11 (diff)
downloadNim-6bf21e7b3dbf203baf23069c33bd79545681f466.tar.gz
fixes #19724; don't be aggressive when you infer sink parameters (#20314)
* fixes #19724; don't be aggressive when you infer sink parameters

* better logic and updated tests

* wip

* fixes tests (#20330)

* restore tests

* try splitPath

Co-authored-by: xflywind <43030857+xflywind@users.noreply.github.com>

* Apply suggestions from code review

* Apply suggestions from code review

Co-authored-by: ringabout <43030857+ringabout@users.noreply.github.com>
Co-authored-by: xflywind <43030857+xflywind@users.noreply.github.com>
Diffstat (limited to 'tests/arc')
-rw-r--r--tests/arc/topt_no_cursor.nim6
1 files changed, 3 insertions, 3 deletions
diff --git a/tests/arc/topt_no_cursor.nim b/tests/arc/topt_no_cursor.nim
index 9585c04a0..0de7f41b9 100644
--- a/tests/arc/topt_no_cursor.nim
+++ b/tests/arc/topt_no_cursor.nim
@@ -138,11 +138,11 @@ if dirExists(this.value):
   par = (dir_1: parentDir(this.value), front_1:
     wasMoved(:tmpD_1)
     `=copy`(:tmpD_1,
-      :tmpD_3 = splitPath do:
+      :tmpD_3 = splitDrive do:
         wasMoved(:tmpD_2)
         `=copy`(:tmpD_2, this.value)
         :tmpD_2
-      :tmpD_3.tail)
+      :tmpD_3.path)
     :tmpD_1)
   `=destroy`(:tmpD_3)
 if dirExists(par.dir):
@@ -357,7 +357,7 @@ proc getSubDirs(parent, front: string): seq[string] = @[]
 method check(this: Foo) {.base.} =
   this.isValid = fileExists(this.value)
   let par = if dirExists(this.value): (dir: this.value, front: "")
-            else: (dir: parentDir(this.value), front: splitPath(this.value).tail)
+            else: (dir: parentDir(this.value), front: splitDrive(this.value).path)
   if dirExists(par.dir):
     this.matchDirs = getSubDirs(par.dir, par.front)
   else: