Use MachineBasicBlock::getParent().

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@11756 91177308-0d34-0410-b5e6-96231b3b80d8
This commit is contained in:
Alkis Evlogimenos 2004-02-23 18:36:38 +00:00
parent e6394e2b62
commit e699b16a76

View File

@ -60,8 +60,7 @@ void ilist_traits<MachineInstr>::transferNodesFromList(
MachineBasicBlock::iterator MachineBasicBlock::getFirstTerminator()
{
const TargetInstrInfo& TII = MachineFunction::get(
getBasicBlock()->getParent()).getTarget().getInstrInfo();
const TargetInstrInfo& TII = getParent()->getTarget().getInstrInfo();
iterator I = end();
while (I != begin() && TII.isTerminatorInstr((--I)->getOpcode()));
if (I != end() && !TII.isTerminatorInstr(I->getOpcode())) ++I;