Comment Comment by pascal_cuoq UBSan does detect and report misaligned pointer accesses in the latest versions of GCC and Clang:https://gcc.godbolt.org/z/xpSbXL parent pascal_cuoq 6 years ago
https://gcc.godbolt.org/z/xpSbXL