[clang] [Clang] Fix crash in alignment builtins with null pointers (PR #224549)
Timm Baeder via cfe-commits
cfe-commits at lists.llvm.org
Mon Sep 21 22:08:50 PDT 2026
tbaederr wrote:
So,
```c++
_Static_assert(__builtin_is_aligned((void *)33, 32), "");
```
this is supposed to....? Work? Not work?
```c++
_Static_assert(__builtin_is_aligned((void *)32, 32), "");
```
this works, but isn't the alignment of both of those pointers the same? Are we really supposed to treat an integer casted to a pointer just like an integer?
https://github.com/llvm/llvm-project/pull/224549
More information about the cfe-commits
mailing list