Skip to content

Commit

Permalink
[nll] librustc_codegen_llvm: change Child signature to fix error poin…
Browse files Browse the repository at this point in the history
…ted out by nll

As explained by eddyb in #53221, "An &ArchiveChild doesn't point into the archive itself, it points to an owned object that itself points to the archive, and LLVMRustArchiveMemberNew copies the ArchiveChild (whereas the current signature suggests it keeps the &ArchiveChild)."
  • Loading branch information
memoryruins committed Aug 10, 2018
1 parent 46b818e commit 085535b
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/librustc_codegen_llvm/llvm/ffi.rs
Expand Up @@ -1564,7 +1564,7 @@ extern "C" {
-> LLVMRustResult;
pub fn LLVMRustArchiveMemberNew(Filename: *const c_char,
Name: *const c_char,
Child: Option<&'a ArchiveChild>)
Child: Option<&ArchiveChild<'a>>)
-> &'a mut RustArchiveMember<'a>;
pub fn LLVMRustArchiveMemberFree(Member: &'a mut RustArchiveMember<'a>);

Expand Down

0 comments on commit 085535b

Please sign in to comment.