forked from OSchip/llvm-project
[DebugInfo] Fix initialization of DwarfCompileUnit::LabelBegin.
This also fixes the condition in the assertion in DwarfCompileUnit::getLabelBegin() because it checked something unrelated to the returned value. Differential Revision: https://reviews.llvm.org/D85437
This commit is contained in:
parent
69eb7e36aa
commit
d400606f8c
|
@ -57,7 +57,7 @@ class DwarfCompileUnit final : public DwarfUnit {
|
|||
DwarfCompileUnit *Skeleton = nullptr;
|
||||
|
||||
/// The start of the unit within its section.
|
||||
MCSymbol *LabelBegin;
|
||||
MCSymbol *LabelBegin = nullptr;
|
||||
|
||||
/// The start of the unit macro info within macro section.
|
||||
MCSymbol *MacroLabelBegin;
|
||||
|
@ -299,7 +299,7 @@ public:
|
|||
void addAddrTableBase();
|
||||
|
||||
MCSymbol *getLabelBegin() const {
|
||||
assert(getSection());
|
||||
assert(LabelBegin && "LabelBegin is not initialized");
|
||||
return LabelBegin;
|
||||
}
|
||||
|
||||
|
|
Loading…
Reference in New Issue