Skip to content

Commit

Permalink
Add missing args handling for gep
Browse files Browse the repository at this point in the history
  • Loading branch information
Y-Nak committed Sep 11, 2023
1 parent 067f42b commit ecb3f59
Showing 1 changed file with 4 additions and 2 deletions.
6 changes: 4 additions & 2 deletions crates/ir/src/insn.rs
Original file line number Diff line number Diff line change
Expand Up @@ -289,7 +289,8 @@ impl InsnData {

Self::Call { args, .. }
| Self::BrTable { args, .. }
| Self::Phi { values: args, .. } => args,
| Self::Phi { values: args, .. }
| Self::Gep { args } => args,

Self::Return { args } => args.as_ref().map(core::slice::from_ref).unwrap_or_default(),

Expand All @@ -308,7 +309,8 @@ impl InsnData {

Self::Call { args, .. }
| Self::BrTable { args, .. }
| Self::Phi { values: args, .. } => args,
| Self::Phi { values: args, .. }
| Self::Gep { args } => args,

Self::Return { args } => args.as_mut().map(core::slice::from_mut).unwrap_or_default(),

Expand Down

0 comments on commit ecb3f59

Please sign in to comment.