This commit is contained in:
parent
a17d996be9
commit
9d488261df
8 changed files with 46 additions and 20 deletions
|
|
@ -59,6 +59,11 @@ proc staticWalkDirImpl(path: string, relative: bool): PNode =
|
|||
result.add newTree(nkPar, newIntNode(nkIntLit, k.ord),
|
||||
newStrNode(nkStrLit, f))
|
||||
|
||||
proc gorgeExWrapper(a: VmArgs) {.nimcall.} =
|
||||
let (s, e) = opGorge(getString(a, 0), getString(a, 1), getString(a, 2),
|
||||
a.currentLineInfo)
|
||||
setResult a, newTree(nkPar, newStrNode(nkStrLit, s), newIntNode(nkIntLit, e))
|
||||
|
||||
proc registerAdditionalOps*(c: PCtx) =
|
||||
wrap1f_math(sqrt)
|
||||
wrap1f_math(ln)
|
||||
|
|
@ -92,3 +97,4 @@ proc registerAdditionalOps*(c: PCtx) =
|
|||
systemop getCurrentExceptionMsg
|
||||
registerCallback c, "stdlib.*.staticWalkDir", proc (a: VmArgs) {.nimcall.} =
|
||||
setResult(a, staticWalkDirImpl(getString(a, 0), getBool(a, 1)))
|
||||
systemop gorgeEx
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue