We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
上次是在skynet中测试。发现在skynet.start中无法正常解码 然后经过一段时间的观察。并且问了skynet的作者。结论是你这边在协程中的绑定lua时的问题。 测试代码如下
pb.import_proto_file("login.proto") local pbstr = pb.encode("login.login", {account="king",password="111111"}) print("encode") local pbmsg=pb.decode("login.login",pbstr) print(tool.dump(pbmsg)) print("=========================") local cor=coroutine.create(function() local msg= pb.decode("login.login", pbstr) print("decode") print(tool.dump(msg)) end) coroutine.resume(cor)
decode " king111111"
The text was updated successfully, but these errors were encountered:
协程中调用时会出错,见 issue #6, 原因为 SteveKChiu/lua-intf#131
Sorry, something went wrong.
让我在README中加个说明。
No branches or pull requests
上次是在skynet中测试。发现在skynet.start中无法正常解码
然后经过一段时间的观察。并且问了skynet的作者。结论是你这边在协程中的绑定lua时的问题。
测试代码如下
pb.import_proto_file("login.proto")
local pbstr = pb.encode("login.login", {account="king",password="111111"})
print("encode")
local pbmsg=pb.decode("login.login",pbstr)
print(tool.dump(pbmsg))
print("=========================")
local cor=coroutine.create(function()
local msg= pb.decode("login.login", pbstr)
print("decode")
print(tool.dump(msg))
end)
coroutine.resume(cor)
打印结果如下
encode
{
["password"] = "111111",
["sdkid"] = 0,
["account"] = "king",
}
decode
"
king111111"
The text was updated successfully, but these errors were encountered: