You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
in these day, many good system software start to be written in go, such as etcd or serf. if such a trend keep on going in future, enable to call go function from luaJIT, may useful like:
localffi=require'ffiex'require'ffiex.go' --> should be optionalffi.godef("path/to/lib.go")
localGO=ffi.gload("golib") --> contains built lib.go.localf=GO.double_fn(ffi.new("GoFloat64", 1.0))
print(f) --> 2.0
probably luaJIT cannot get along with some feature of go like channel or goroutine without modification of luaJIT itself, but just call some go function and receive result still useful, I think.
with https://codereview.appspot.com/9733044/ , seems it already works,
(I know that gccgo can do this, but it will require re-build go code in most case, so its not handy like current luaJIT FFI)
I tried that but unfortunately, current go's -shared option cannot create the one which is loadable from luaJIT, but at least it contains mach-o-x86-64 format part in OSX go build.
in these day, many good system software start to be written in go, such as etcd or serf. if such a trend keep on going in future, enable to call go function from luaJIT, may useful like:
probably luaJIT cannot get along with some feature of go like channel or goroutine without modification of luaJIT itself, but just call some go function and receive result still useful, I think.
with https://codereview.appspot.com/9733044/ , seems it already works,
(I know that gccgo can do this, but it will require re-build go code in most case, so its not handy like current luaJIT FFI)
I tried that but unfortunately, current go's -shared option cannot create the one which is loadable from luaJIT, but at least it contains mach-o-x86-64 format part in OSX go build.
The text was updated successfully, but these errors were encountered: