Added a catch-all
@@ -392,6 +392,7 @@ fn translate_expr(
arr_typs: &ArrayTypes,
e: &Expr,
) -> TranslationResult<Spanned<ExprTranslationResult>> {
+ #[allow(unreachable_patterns)]
match &e.kind {
ExprKind::Binary(op, e1, e2) => Ok((
ExprTranslationResult::TransExpr(Expression::Binary(
@@ -1008,6 +1009,10 @@ fn translate_expr(
sess.span_rustspec_err(e.span.clone(), "underscores are not allowed in Hacspec");
Err(())
}
+ _ => {
+ sess.span_rustspec_err(e.span.clone(), "this expression is not allowed in Hacspec");
+ Err(())
+ }
}
}
