about summary refs log tree commit diff stats
path: root/src/utils
diff options
context:
space:
mode:
authorbptato <nincsnevem662@gmail.com>2023-09-07 16:52:49 +0200
committerbptato <nincsnevem662@gmail.com>2023-09-07 16:52:49 +0200
commit62d78f3ca867b159d699d9580805c7c88e76bded (patch)
treec6371ba1784fe73078a25cd1278ce116c020898b /src/utils
parentc63e86558f56a6498b9989e01b896dc18a9e3384 (diff)
downloadchawan-62d78f3ca867b159d699d9580805c7c88e76bded.tar.gz
twtstr: remove toLowerAscii2
Diffstat (limited to 'src/utils')
-rw-r--r--src/utils/twtstr.nim15
1 files changed, 0 insertions, 15 deletions
diff --git a/src/utils/twtstr.nim b/src/utils/twtstr.nim
index d3cc8bd8..3e8b5779 100644
--- a/src/utils/twtstr.nim
+++ b/src/utils/twtstr.nim
@@ -82,21 +82,6 @@ const lowerChars = (func(): array[char, char] =
 func tolower*(c: char): char =
   return lowerChars[c]
 
-func toLowerAscii2*(str: string): string =
-  var i = 0
-  block noconv:
-    while i < str.len:
-      let c = str[i]
-      if c in AsciiUpperAlpha:
-        break noconv
-      inc i
-    return str
-  result = newString(str.len)
-  prepareMutation(result)
-  copyMem(addr result[0], unsafeAddr str[0], i)
-  for i in i ..< str.len:
-    result[i] = str[i].tolower()
-
 proc mtoLowerAscii*(str: var string) =
   for i in 0 ..< str.len:
     str[i] = str[i].tolower()