[libc-commits] [PATCH] D159458: [libc] Fix printf %p format
Joseph Huber via Phabricator via libc-commits
libc-commits at lists.llvm.org
Tue Sep 5 14:50:45 PDT 2023
jhuber6 accepted this revision.
jhuber6 added a comment.
This revision is now accepted and ready to land.
Thanks.
================
Comment at: libc/src/stdio/printf_core/ptr_converter.h:25
+
if (to_conv.conv_val_ptr == (void *)(nullptr)) {
+ constexpr char nullptr_str[] = "(nullptr)";
----------------
Why do we need to cast `nullptr` here? Also do we have the raw value itself? We could just check that for zero.
Repository:
rG LLVM Github Monorepo
CHANGES SINCE LAST ACTION
https://reviews.llvm.org/D159458/new/
https://reviews.llvm.org/D159458
More information about the libc-commits
mailing list