Skip to content

Commit

Permalink
ensure size_of matches its docs
Browse files Browse the repository at this point in the history
  • Loading branch information
Dante-Broggi committed Nov 12, 2019
1 parent b0c72aa commit 10946b7
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/librustc_mir/interpret/intrinsics.rs
Original file line number Diff line number Diff line change
Expand Up @@ -70,7 +70,7 @@ crate fn eval_nullary_intrinsic<'tcx>(
let n = match name {
"pref_align_of" => layout.pref_pos.align.pref.bytes(),
"min_align_of" => layout.pref_pos.align.abi.bytes(),
"size_of" => layout.pref_pos.size.bytes(),
"size_of" => layout.pref_pos.stride().bytes(),
_ => bug!(),
};
ty::Const::from_usize(tcx, n)
Expand Down

0 comments on commit 10946b7

Please sign in to comment.