Nim embedded inside Python

2020-09-01 Thread dsrw
If you call a specific proc, you get back a (PNode)[, which you can get a value out of. Something like: import compiler / [nimeval] writeFile "script.nim", "proc main*: string = \"hello world\"" let

Nim embedded inside Python

2020-09-01 Thread juancarlospaco
Any ideas how to implement a return from the interpreter?, something like simple JSON string API Nim<\--->Python.

Nim embedded inside Python

2020-08-31 Thread juancarlospaco
$ echo "echo 42" > example.nims $ pip install nim4py==0c42da8 $ python3.8 >>> import nim4py >>> nim4py.nimscript("example.nims", ["/home/juan/.choosenim/toolchains/nim-1.3.5/lib/"]) 42 >>> Run *