aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorGanesh Viswanathan <dev@genotrance.com>2019-04-06 18:33:40 -0500
committerGanesh Viswanathan <dev@genotrance.com>2019-04-06 18:33:40 -0500
commit2bad84c4c174009890cb07ca7016b8353fb6da40 (patch)
treeed99329633982031086b5b0ba7ef725f88b7e8f7
parent8fcf8011a50d574fef2e87f0d3db2d7a9bcffd93 (diff)
downloadnimterop-2bad84c4c174009890cb07ca7016b8353fb6da40.tar.gz
nimterop-2bad84c4c174009890cb07ca7016b8353fb6da40.zip
Fix #123
-rw-r--r--nimterop/getters.nim6
1 files changed, 3 insertions, 3 deletions
diff --git a/nimterop/getters.nim b/nimterop/getters.nim
index 3510e27..c9aecf8 100644
--- a/nimterop/getters.nim
+++ b/nimterop/getters.nim
@@ -74,7 +74,7 @@ const gTypeMap = {
}.toTable()
proc sanitizePath*(path: string): string =
- path.multiReplace([("\\\\", $DirSep), ("\\", $DirSep), ("//", $DirSep)])
+ path.multiReplace([("\\\\", $DirSep), ("\\", $DirSep), ("/", $DirSep)])
proc getType*(str: string): string =
if str == "void":
@@ -216,7 +216,7 @@ proc getPreprocessor*(fullpath: string, mode = "cpp"): string =
for def in gStateRT.defines:
cmd &= &"-D{def} "
- cmd &= &"\"{fullpath.quoteShell}\""
+ cmd &= &"{fullpath.quoteShell}"
# Include content only from file
for line in execAction(cmd).splitLines():
@@ -231,7 +231,7 @@ proc getPreprocessor*(fullpath: string, mode = "cpp"): string =
start = true
elif gStateRT.recurse:
let
- pDir = sfile.expandFilename().parentDir()
+ pDir = sfile.expandFilename().parentDir().sanitizePath()
if pDir.len == 0 or pDir in saniLine:
start = true
else: