Skip to content

Commit

Permalink
update make_indirect_byval comment about missing fix (this PR is the …
Browse files Browse the repository at this point in the history
…fix)
  • Loading branch information
erikdesjardins committed Mar 11, 2024
1 parent 207fe38 commit 818f130
Showing 1 changed file with 1 addition and 3 deletions.
4 changes: 1 addition & 3 deletions compiler/rustc_target/src/abi/call/mod.rs
Original file line number Diff line number Diff line change
Expand Up @@ -633,10 +633,8 @@ impl<'a, Ty> ArgAbi<'a, Ty> {
/// If the resulting alignment differs from the type's alignment,
/// the argument will be copied to an alloca with sufficient alignment,
/// either in the caller (if the type's alignment is lower than the byval alignment)
/// or in the callee (if the type"s alignment is higher than the byval alignment),
/// or in the callee (if the type"s alignment is higher than the byval alignment),
/// to ensure that Rust code never sees an underaligned pointer.
///
/// † This is currently broken, see <https://github.com/rust-lang/rust/pull/122212>.
pub fn make_indirect_byval(&mut self, byval_align: Option<Align>) {
assert!(!self.layout.is_unsized(), "used byval ABI for unsized layout");
self.make_indirect();
Expand Down

0 comments on commit 818f130

Please sign in to comment.