Skip to content

Commit 65d9d54

Browse files
authored
Fix for destructor error (#159)
Co-authored-by: @fboemer
1 parent 23ea857 commit 65d9d54

File tree

3 files changed

+12
-1
lines changed

3 files changed

+12
-1
lines changed

CMakeLists.txt

Lines changed: 9 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -66,6 +66,15 @@ if (NOT HEXL_FPGA_COMPATIBILITY)
6666
set(HEXL_FPGA_COMPATIBILITY "0" CACHE INTERNAL "Set FPGA compatibility mask" FORCE)
6767
endif()
6868

69+
# Get the current working branch
70+
execute_process(
71+
COMMAND git rev-parse --abbrev-ref HEAD
72+
WORKING_DIRECTORY ${CMAKE_SOURCE_DIR}
73+
OUTPUT_VARIABLE GIT_BRANCH
74+
OUTPUT_STRIP_TRAILING_WHITESPACE
75+
)
76+
77+
message(STATUS "HEXL BRANCH: ${GIT_BRANCH}")
6978
message(STATUS "CMAKE_BUILD_TYPE: ${CMAKE_BUILD_TYPE}")
7079
message(STATUS "CMAKE_C_COMPILER: ${CMAKE_C_COMPILER}")
7180
message(STATUS "CMAKE_CXX_COMPILER: ${CMAKE_CXX_COMPILER}")

hexl/include/hexl/ntt/ntt.hpp

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -40,7 +40,7 @@ class NTT {
4040
NTT() = default;
4141

4242
/// @brief Destructs the NTT object
43-
~NTT() = default;
43+
~NTT();
4444

4545
/// @brief Initializes an NTT object with degree \p degree and modulus \p q.
4646
/// @param[in] degree also known as N. Size of the NTT transform. Must be a

hexl/ntt/ntt-internal.cpp

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -51,6 +51,8 @@ NTT::NTT(uint64_t degree, uint64_t q, uint64_t root_of_unity,
5151
NTT::NTT(uint64_t degree, uint64_t q, std::shared_ptr<AllocatorBase> alloc_ptr)
5252
: NTT(degree, q, MinimalPrimitiveRoot(2 * degree, q), alloc_ptr) {}
5353

54+
NTT::~NTT() = default;
55+
5456
void NTT::ComputeRootOfUnityPowers() {
5557
AlignedVector64<uint64_t> root_of_unity_powers(m_degree, 0, m_aligned_alloc);
5658
AlignedVector64<uint64_t> inv_root_of_unity_powers(m_degree, 0,

0 commit comments

Comments
 (0)