Fix #181 - cPluginPath()

This commit is contained in:
Ganesh Viswanathan 2020-04-12 12:56:50 -05:00
commit 0afb634b59
3 changed files with 24 additions and 10 deletions

View file

@ -11,14 +11,7 @@ cDefine("FORCE")
cIncludeDir testsIncludeDir()
cCompile cSearchPath("test.c")
cPlugin:
import strutils
proc onSymbol*(sym: var Symbol) {.exportc, dynlib.} =
if sym.name == "_Kernel":
sym.name = "uKernel"
else:
sym.name = sym.name.strip(chars={'_'})
cPluginPath("tests/tnimterop_c_plugin.nim")
cOverride:
type

View file

@ -0,0 +1,7 @@
import strutils
proc onSymbol*(sym: var Symbol) {.exportc, dynlib.} =
if sym.name == "_Kernel":
sym.name = "uKernel"
else:
sym.name = sym.name.strip(chars={'_'})