parent
4cb6f4f85d
commit
5c22c8850e
|
@ -170,7 +170,7 @@ fn section_kind(section: &object::Section) -> SectionKind {
|
|||
.and_then(|name| match name {
|
||||
".init" | ".text" | ".vmtext" | ".dbgtext" => Some(SectionKind::Text),
|
||||
".ctors" | ".dtors" | ".data" | ".rodata" | ".sdata" | ".sdata2" | "extab"
|
||||
| "extabindex" => Some(SectionKind::Data),
|
||||
| "extabindex" | ".BINARY" => Some(SectionKind::Data),
|
||||
".bss" | ".sbss" | ".sbss2" => Some(SectionKind::UninitializedData),
|
||||
_ => None,
|
||||
})
|
||||
|
|
|
@ -212,7 +212,7 @@ impl ObjSection {
|
|||
fn section_kind_for_section(section_name: &str) -> Result<ObjSectionKind> {
|
||||
Ok(match section_name {
|
||||
".init" | ".text" | ".dbgtext" | ".vmtext" => ObjSectionKind::Code,
|
||||
".ctors" | ".dtors" | ".rodata" | ".sdata2" | "extab" | "extabindex" => {
|
||||
".ctors" | ".dtors" | ".rodata" | ".sdata2" | "extab" | "extabindex" | ".BINARY" => {
|
||||
ObjSectionKind::ReadOnlyData
|
||||
}
|
||||
".bss" | ".sbss" | ".sbss2" => ObjSectionKind::Bss,
|
||||
|
|
|
@ -859,7 +859,8 @@ where
|
|||
write!(w, ".section {}", section.name)?;
|
||||
write!(w, ", \"a\", @nobits")?;
|
||||
}
|
||||
".ctors" | ".dtors" | ".ctors$10" | ".dtors$10" | ".dtors$15" | "extab" | "extabindex" => {
|
||||
".ctors" | ".dtors" | ".ctors$10" | ".dtors$10" | ".dtors$15" | "extab" | "extabindex"
|
||||
| ".BINARY" => {
|
||||
write!(w, ".section {}", section.name)?;
|
||||
write!(w, ", \"a\"")?;
|
||||
}
|
||||
|
|
Loading…
Reference in New Issue