Details
-
Bug
-
Status: Closed
-
Major
-
Resolution: Fixed
-
0.14.2
Description
in thrift file:
const i64 ALuaConst= 0x1
in generated lua file:
ALuaConst = lualongnumber.new('')
bug is here:
https://github.com/apache/thrift/blob/4434ee92d5141578cecac95ee53e3563101b9ecd/compiler/cpp/src/thrift/generate/t_lua_generator.cc#L262
should replace get_string() with get_integer()
beacuse according to
https://github.com/apache/thrift/blob/4434ee92d5141578cecac95ee53e3563101b9ecd/compiler/cpp/src/thrift/parse/t_scope.h#L153
when const type == i64, set_string() is unreachable, then get_string() will always return "".
Attachments
Issue Links
- links to