diff --git a/src/Native/LibTorchSharp/THSJIT.cpp b/src/Native/LibTorchSharp/THSJIT.cpp index a0a4a5d0c..8802b6e66 100644 --- a/src/Native/LibTorchSharp/THSJIT.cpp +++ b/src/Native/LibTorchSharp/THSJIT.cpp @@ -599,7 +599,7 @@ int8_t THSJIT_TensorType_dtype(const JITTensorType type) } } -void THSJIT_TensorType_sizes(const JITTensorType type, int64_t* (*allocator)(int64_t length)) +void THSJIT_TensorType_sizes(const JITTensorType type, int64_t* (*allocator)(size_t length)) { //CATCH( auto& t = *type; diff --git a/src/Native/LibTorchSharp/THSJIT.h b/src/Native/LibTorchSharp/THSJIT.h index 81e6d51ad..5d0e19551 100644 --- a/src/Native/LibTorchSharp/THSJIT.h +++ b/src/Native/LibTorchSharp/THSJIT.h @@ -57,7 +57,7 @@ EXPORT_API(int8_t) THSJIT_Type_kind(JITType handle); EXPORT_API(void*) THSJIT_Type_cast(const JITType type); EXPORT_API(int8_t) THSJIT_TensorType_dtype(const JITTensorType type); -EXPORT_API(void) THSJIT_TensorType_sizes(const JITTensorType type, int64_t* (*allocator)(int64_t length)); +EXPORT_API(void) THSJIT_TensorType_sizes(const JITTensorType type, int64_t* (*allocator)(size_t length)); EXPORT_API(void) THSJIT_Type_dispose(const JITType type); EXPORT_API(void) THSJIT_TensorType_dispose(const JITTensorType type);