fix: use std::memcpy instead of *reinterpret_cast#3514
fix: use std::memcpy instead of *reinterpret_cast#3514ianna merged 7 commits intoscikit-hep:mainfrom
Conversation
|
In order to test if it still produces aliasing errors I used diff --git i/awkward-cpp/CMakeLists.txt w/awkward-cpp/CMakeLists.txt
index 574d197f..b0ea478b 100644
--- i/awkward-cpp/CMakeLists.txt
+++ w/awkward-cpp/CMakeLists.txt
@@ -2,6 +2,10 @@
cmake_minimum_required(VERSION 3.15...3.30)
+set(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -Werror=strict-aliasing")
+set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -Werror=strict-aliasing")
+
+
if(NOT DEFINED SKBUILD)
set(SKBUILD_PROJECT_NAME awkward_cpp)
set(SKBUILD_PROJECT_VERSION 0.0.0) |
Codecov ReportAll modified and coverable lines are covered by tests ✅
Additional details and impacted files🚀 New features to boost your workflow:
|
|
@henryiii - FYI, the windows build fails for 3.13 on this PR. Is it something you are looking into? Thanks! |
I guess, these changes need to go first: |
ianna
left a comment
There was a problem hiding this comment.
@APN-Pucky - thank you for fixing this! Looks great. I’m merging it. Thanks!
|
@all-contributors please add @APN-Pucky for code |
|
I've put up a pull request to add @APN-Pucky! 🎉 |
|
Thanks @ianna ! |
Things to consider:
Closes: #3513