Don't depend on string.h in codegen (#8299)

This commit is contained in:
Yuriy Glukhov 2018-07-13 18:41:59 +03:00 • committed by Andreas Rumpf
commit dfe3f16022
9 changed files with 87 additions and 54 deletions

View file

@ -25,6 +25,8 @@ proc c_memset(p: pointer, value: cint, size: csize): pointer {.
importc: "memset", header: "<string.h>", discardable.}
proc c_strcmp(a, b: cstring): cint {.
importc: "strcmp", header: "<string.h>", noSideEffect.}
proc c_strlen(a: cstring): csize {.
importc: "strlen", header: "<string.h>", noSideEffect.}
when defined(linux) and defined(amd64):
type