diff options
| author | Matt Arsenault <Matthew.Arsenault@amd.com> | 2024-04-22 10:48:25 +0200 |
|---|---|---|
| committer | Matt Arsenault <arsenm2@gmail.com> | 2024-04-22 11:35:09 +0200 |
| commit | bd84f5d5d71ee26d9552a9cd96ef058cfb8a39fc (patch) | |
| tree | 82ab26ab7888bdf1a7e9bef85043709bf7319c52 /clang/lib/CodeGen/CGExprScalar.cpp | |
| parent | c88b84d467a201129e329b0bca3425fef326db03 (diff) | |
clang: Remove unnecessary pointer bitcast
Diffstat (limited to 'clang/lib/CodeGen/CGExprScalar.cpp')
| -rw-r--r-- | clang/lib/CodeGen/CGExprScalar.cpp | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/clang/lib/CodeGen/CGExprScalar.cpp b/clang/lib/CodeGen/CGExprScalar.cpp index c76052ff6280..40a5cd20c3d7 100644 --- a/clang/lib/CodeGen/CGExprScalar.cpp +++ b/clang/lib/CodeGen/CGExprScalar.cpp @@ -1540,7 +1540,7 @@ Value *ScalarExprEmitter::EmitScalarConversion(Value *Src, QualType SrcType, if (auto DstPT = dyn_cast<llvm::PointerType>(DstTy)) { // The source value may be an integer, or a pointer. if (isa<llvm::PointerType>(SrcTy)) - return Builder.CreateBitCast(Src, DstTy, "conv"); + return Src; assert(SrcType->isIntegerType() && "Not ptr->ptr or int->ptr conversion?"); // First, convert to the correct width so that we control the kind of |
