aboutsummaryrefslogtreecommitdiff
path: root/llvm/lib/Bitcode/Reader/BitcodeReader.cpp
diff options
context:
space:
mode:
authorArthur Eubanks <aeubanks@google.com>2021-08-17 20:25:16 -0700
committerArthur Eubanks <aeubanks@google.com>2021-08-17 21:05:41 -0700
commit3f4d00bc3b514d3218089fce15457457fc3312c3 (patch)
tree9f545ececa0fc35c7dcc5affff27b8f20044b95a /llvm/lib/Bitcode/Reader/BitcodeReader.cpp
parentde0ae9e89ec437d9f58e4b2da04d210c161854a3 (diff)
downloadllvm-3f4d00bc3b514d3218089fce15457457fc3312c3.zip
llvm-3f4d00bc3b514d3218089fce15457457fc3312c3.tar.gz
llvm-3f4d00bc3b514d3218089fce15457457fc3312c3.tar.bz2
[NFC] More get/removeAttribute() cleanup
Diffstat (limited to 'llvm/lib/Bitcode/Reader/BitcodeReader.cpp')
-rw-r--r--llvm/lib/Bitcode/Reader/BitcodeReader.cpp5
1 files changed, 2 insertions, 3 deletions
diff --git a/llvm/lib/Bitcode/Reader/BitcodeReader.cpp b/llvm/lib/Bitcode/Reader/BitcodeReader.cpp
index bc967f6..eb6a7f3 100644
--- a/llvm/lib/Bitcode/Reader/BitcodeReader.cpp
+++ b/llvm/lib/Bitcode/Reader/BitcodeReader.cpp
@@ -5567,9 +5567,8 @@ Error BitcodeReader::materialize(GlobalValue *GV) {
// Remove incompatible attributes on function calls.
if (auto *CI = dyn_cast<CallBase>(&I)) {
- CI->removeAttributes(AttributeList::ReturnIndex,
- AttributeFuncs::typeIncompatible(
- CI->getFunctionType()->getReturnType()));
+ CI->removeRetAttrs(AttributeFuncs::typeIncompatible(
+ CI->getFunctionType()->getReturnType()));
for (unsigned ArgNo = 0; ArgNo < CI->arg_size(); ++ArgNo)
CI->removeParamAttrs(ArgNo, AttributeFuncs::typeIncompatible(