Replace Body::basic_blocks() with field access
This commit is contained in:
@@ -331,11 +331,6 @@ impl<'tcx> Body<'tcx> {
|
||||
body
|
||||
}
|
||||
|
||||
#[inline]
|
||||
pub fn basic_blocks(&self) -> &IndexVec<BasicBlock, BasicBlockData<'tcx>> {
|
||||
&self.basic_blocks
|
||||
}
|
||||
|
||||
#[inline]
|
||||
pub fn basic_blocks_mut(&mut self) -> &mut IndexVec<BasicBlock, BasicBlockData<'tcx>> {
|
||||
self.basic_blocks.as_mut()
|
||||
@@ -490,7 +485,7 @@ impl<'tcx> Index<BasicBlock> for Body<'tcx> {
|
||||
|
||||
#[inline]
|
||||
fn index(&self, index: BasicBlock) -> &BasicBlockData<'tcx> {
|
||||
&self.basic_blocks()[index]
|
||||
&self.basic_blocks[index]
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user