[PATCH] D138426: Fix #58958 on github
Alexey Kreshchuk via Phabricator via cfe-commits
cfe-commits at lists.llvm.org
Tue Nov 22 06:19:28 PST 2022
krsch added inline comments.
================
Comment at: clang/lib/Sema/SemaFixItUtils.cpp:136-137
+ // Do no take address of const pointer to get void*
+ const PointerType *FromPtrTy = dyn_cast<PointerType>(FromQTy);
+ const PointerType *ToPtrTy = dyn_cast<PointerType>(ToQTy);
+ if (FromPtrTy && FromPtrTy->getPointeeType().isConstQualified() &&
----------------
xazax.hun wrote:
> xazax.hun wrote:
> > Nit: we usually try to avoid repeating types.
> Although the rest of the function clearly does not follow this guideline so feel free to leave it as is.
The rest of the function was made this way in commit 1e95bc0f4063e, so I thought this is the style for this part of the codebase
Repository:
rG LLVM Github Monorepo
CHANGES SINCE LAST ACTION
https://reviews.llvm.org/D138426/new/
https://reviews.llvm.org/D138426
More information about the cfe-commits
mailing list