Skip to content

Commit

Permalink
remove unused SoftSlice expression variant
Browse files Browse the repository at this point in the history
  • Loading branch information
hlorenzi committed Dec 27, 2023
1 parent cbe63b6 commit 249e1c3
Show file tree
Hide file tree
Showing 3 changed files with 0 additions and 13 deletions.
5 changes: 0 additions & 5 deletions src/expr/eval.rs
Original file line number Diff line number Diff line change
Expand Up @@ -646,11 +646,6 @@ impl expr::Expr
}
}

&expr::Expr::SoftSlice(_, _, _, _, ref inner) =>
{
inner.eval_with_ctx(report, ctx, provider)
}

&expr::Expr::Block(_, ref exprs) =>
{
let mut result = expr::Value::Void;
Expand Down
2 changes: 0 additions & 2 deletions src/expr/expression.rs
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,6 @@ pub enum Expr
BinaryOp(diagn::Span, diagn::Span, BinaryOp, Box<Expr>, Box<Expr>),
TernaryOp(diagn::Span, Box<Expr>, Box<Expr>, Box<Expr>),
BitSlice(diagn::Span, diagn::Span, usize, usize, Box<Expr>),
SoftSlice(diagn::Span, diagn::Span, usize, usize, Box<Expr>),
Block(diagn::Span, Vec<Expr>),
Call(diagn::Span, Box<Expr>, Vec<Expr>),
Asm(diagn::Span, Vec<syntax::Token>),
Expand Down Expand Up @@ -85,7 +84,6 @@ impl Expr
&Expr::BinaryOp (span, ..) => span,
&Expr::TernaryOp(span, ..) => span,
&Expr::BitSlice (span, ..) => span,
&Expr::SoftSlice(span, ..) => span,
&Expr::Block (span, ..) => span,
&Expr::Call (span, ..) => span,
&Expr::Asm (span, ..) => span,
Expand Down
6 changes: 0 additions & 6 deletions src/expr/inspect.rs
Original file line number Diff line number Diff line change
Expand Up @@ -94,9 +94,6 @@ impl expr::Expr

expr::Expr::BitSlice(_, _, left, right, _) =>
Some(left - right),

expr::Expr::SoftSlice(_, _, left, right, _) =>
Some(left - right),

expr::Expr::TernaryOp(_, _, ref true_branch, ref false_branch) =>
{
Expand Down Expand Up @@ -180,9 +177,6 @@ impl expr::Expr

expr::Expr::BitSlice(_, _, _, _, ref expr) =>
expr.is_value_statically_known(provider),

expr::Expr::SoftSlice(_, _, _, _, ref expr) =>
expr.is_value_statically_known(provider),

expr::Expr::TernaryOp(_, ref condition, ref true_branch, ref false_branch) =>
{
Expand Down

0 comments on commit 249e1c3

Please sign in to comment.