chore: fix thrift deprecation warnings

This commit is contained in:
Marcus Holland-Moritz 2023-11-20 22:54:29 +01:00
parent 754eb33bb8
commit 99e7680090
2 changed files with 10 additions and 3 deletions

View File

@ -624,6 +624,7 @@ add_custom_command(
COMMAND ${CMAKE_COMMAND} -E copy ${CMAKE_CURRENT_SOURCE_DIR}/fbthrift/thrift/lib/thrift/frozen.thrift
${CMAKE_CURRENT_BINARY_DIR}/thrift/lib/thrift/
COMMAND ${CMAKE_CURRENT_BINARY_DIR}/bin/thrift1
-I ${CMAKE_CURRENT_SOURCE_DIR}/fbthrift
-o ${CMAKE_CURRENT_BINARY_DIR}/thrift/lib/thrift
--gen mstch_cpp2
frozen.thrift
@ -645,6 +646,7 @@ add_custom_command(
COMMAND ${CMAKE_COMMAND} -E copy ${CMAKE_CURRENT_SOURCE_DIR}/thrift/metadata.thrift
${CMAKE_CURRENT_BINARY_DIR}/thrift/dwarfs/metadata.thrift
COMMAND ${CMAKE_CURRENT_BINARY_DIR}/bin/thrift1
-I ${CMAKE_CURRENT_SOURCE_DIR}/fbthrift
-o ${CMAKE_CURRENT_BINARY_DIR}/thrift/dwarfs
--gen mstch_cpp2:frozen2
metadata.thrift

View File

@ -19,11 +19,16 @@
* along with dwarfs. If not, see <https://www.gnu.org/licenses/>.
*/
include "thrift/annotation/cpp.thrift"
namespace cpp2 dwarfs.thrift.metadata
typedef i16 (cpp2.type = "uint16_t") UInt16
typedef i32 (cpp2.type = "uint32_t") UInt32
typedef i64 (cpp2.type = "uint64_t") UInt64
@cpp.Type{name = "uint16_t"}
typedef i16 UInt16
@cpp.Type{name = "uint32_t"}
typedef i32 UInt32
@cpp.Type{name = "uint64_t"}
typedef i64 UInt64
/**
* One chunk of data