From 967d6a691499368cbb942e178a2526f5c00ce879 Mon Sep 17 00:00:00 2001 From: Rafael Espindola Date: Thu, 21 May 2015 21:02:35 +0000 Subject: Stop forwarding (get|set)Aligment from MCSectionData to MCSection. llvm-svn: 237956 --- llvm/lib/MC/MCObjectStreamer.cpp | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) (limited to 'llvm/lib/MC/MCObjectStreamer.cpp') diff --git a/llvm/lib/MC/MCObjectStreamer.cpp b/llvm/lib/MC/MCObjectStreamer.cpp index b6d67a81771..3f32a36194f 100644 --- a/llvm/lib/MC/MCObjectStreamer.cpp +++ b/llvm/lib/MC/MCObjectStreamer.cpp @@ -380,8 +380,9 @@ void MCObjectStreamer::EmitValueToAlignment(unsigned ByteAlignment, insert(new MCAlignFragment(ByteAlignment, Value, ValueSize, MaxBytesToEmit)); // Update the maximum alignment on the current section if necessary. - if (ByteAlignment > getCurrentSectionData()->getAlignment()) - getCurrentSectionData()->setAlignment(ByteAlignment); + MCSection *CurSec = getCurrentSection().first; + if (ByteAlignment > CurSec->getAlignment()) + CurSec->setAlignment(ByteAlignment); } void MCObjectStreamer::EmitCodeAlignment(unsigned ByteAlignment, -- cgit v1.2.3