Skip to content

Commit

Permalink
Browse files Browse the repository at this point in the history
  • Loading branch information
juntyr committed Sep 17, 2022
1 parent 1e9ed35 commit 8336364
Showing 1 changed file with 3 additions and 1 deletion.
4 changes: 3 additions & 1 deletion src/lib.rs
Original file line number Diff line number Diff line change
Expand Up @@ -372,7 +372,9 @@ impl<'a> TypeLayoutGraph<'a> {

while i < self.tys.len() {
// The first free slot can be used to insert the ty
let Some(cached_ty) = self.tys[i] else {
let cached_ty = if let Some(cached_ty) = self.tys[i] {
cached_ty
} else {
self.tys[i] = Some(ty);

return true;
Expand Down

0 comments on commit 8336364

Please sign in to comment.