1
0
mirror of https://github.com/RPCS3/llvm-mirror.git synced 2024-11-22 18:54:02 +01:00

Use unique_ptr to hold MCInstrInfo

llvm-svn: 340654
This commit is contained in:
Vitaly Buka 2018-08-24 21:03:35 +00:00
parent c9994c1345
commit 52de92c98c

View File

@ -351,8 +351,9 @@ ELFObjectFileBase::getPltAddresses() const {
default:
return {};
}
std::unique_ptr<const MCInstrInfo> MII(T->createMCInstrInfo());
std::unique_ptr<const MCInstrAnalysis> MIA(
T->createMCInstrAnalysis(T->createMCInstrInfo()));
T->createMCInstrAnalysis(MII.get()));
if (!MIA)
return {};
Optional<SectionRef> Plt = None, RelaPlt = None, GotPlt = None;