- // Stuff that's in llvm-wrapper/ because it's not upstream yet.
-
- /// Opens an object file.
- pub fn LLVMCreateObjectFile(
- MemBuf: &'static mut MemoryBuffer,
- ) -> Option<&'static mut ObjectFile>;
- /// Closes an object file.
- pub fn LLVMDisposeObjectFile(ObjFile: &'static mut ObjectFile);
-
- /// Enumerates the sections in an object file.
- pub fn LLVMGetSections(ObjFile: &'a ObjectFile) -> &'a mut SectionIterator<'a>;
- /// Destroys a section iterator.
- pub fn LLVMDisposeSectionIterator(SI: &'a mut SectionIterator<'a>);
- /// Returns `true` if the section iterator is at the end of the section
- /// list:
- pub fn LLVMIsSectionIteratorAtEnd(ObjFile: &'a ObjectFile, SI: &SectionIterator<'a>) -> Bool;
- /// Moves the section iterator to point to the next section.
- pub fn LLVMMoveToNextSection(SI: &SectionIterator<'_>);
- /// Returns the current section size.
- pub fn LLVMGetSectionSize(SI: &SectionIterator<'_>) -> c_ulonglong;
- /// Returns the current section contents as a string buffer.
- pub fn LLVMGetSectionContents(SI: &SectionIterator<'_>) -> *const c_char;
-
- /// Reads the given file and returns it as a memory buffer. Use
- /// LLVMDisposeMemoryBuffer() to get rid of it.
- pub fn LLVMRustCreateMemoryBufferWithContentsOfFile(
- Path: *const c_char,
- ) -> Option<&'static mut MemoryBuffer>;
-