os.nim: do not include and import ospaths
This commit is contained in:
parent
7d8ef01e29
commit
8ce4273864
1 changed files with 1 additions and 9 deletions
|
|
@ -29,14 +29,6 @@ else:
|
||||||
import ospaths
|
import ospaths
|
||||||
export ospaths
|
export ospaths
|
||||||
|
|
||||||
when defined(posix):
|
|
||||||
when NoFakeVars:
|
|
||||||
const pathMax = 5000 # doesn't matter really. The concept of PATH_MAX
|
|
||||||
# doesn't work anymore on modern OSes.
|
|
||||||
else:
|
|
||||||
var
|
|
||||||
pathMax {.importc: "PATH_MAX", header: "<stdlib.h>".}: cint
|
|
||||||
|
|
||||||
proc c_remove(filename: cstring): cint {.
|
proc c_remove(filename: cstring): cint {.
|
||||||
importc: "remove", header: "<stdio.h>".}
|
importc: "remove", header: "<stdio.h>".}
|
||||||
proc c_rename(oldname, newname: cstring): cint {.
|
proc c_rename(oldname, newname: cstring): cint {.
|
||||||
|
|
@ -1388,7 +1380,7 @@ proc moveDir*(source, dest: string) {.tags: [ReadIOEffect, WriteIOEffect].} =
|
||||||
copyDir(source, dest)
|
copyDir(source, dest)
|
||||||
removeDir(source)
|
removeDir(source)
|
||||||
|
|
||||||
include ospaths
|
#include ospaths
|
||||||
|
|
||||||
proc expandSymlink*(symlinkPath: string): string =
|
proc expandSymlink*(symlinkPath: string): string =
|
||||||
## Returns a string representing the path to which the symbolic link points.
|
## Returns a string representing the path to which the symbolic link points.
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue