Skip to content

Commit 2f15ccf

Browse files
committed
remove rem_exprt
The expression isn't usable, and there are no users. Depending on the desired semantics, use either floatbv_rem or floatbv_mod instead.
1 parent 71da49a commit 2f15ccf

File tree

2 files changed

+0
-45
lines changed

2 files changed

+0
-45
lines changed

src/util/irep_ids.def

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -237,7 +237,6 @@ IREP_ID_ONE(array_copy)
237237
IREP_ID_ONE(array_list)
238238
IREP_ID_ONE(euclidean_mod)
239239
IREP_ID_ONE(mod)
240-
IREP_ID_ONE(rem)
241240
IREP_ID_ONE(shr)
242241
IREP_ID_ONE(ashr)
243242
IREP_ID_ONE(lshr)

src/util/std_expr.h

Lines changed: 0 additions & 44 deletions
Original file line numberDiff line numberDiff line change
@@ -1135,50 +1135,6 @@ inline euclidean_mod_exprt &to_euclidean_mod_expr(exprt &expr)
11351135
return ret;
11361136
}
11371137

1138-
/// \brief Remainder of division
1139-
class rem_exprt:public binary_exprt
1140-
{
1141-
public:
1142-
rem_exprt(exprt _lhs, exprt _rhs)
1143-
: binary_exprt(std::move(_lhs), ID_rem, std::move(_rhs))
1144-
{
1145-
}
1146-
};
1147-
1148-
template <>
1149-
inline bool can_cast_expr<rem_exprt>(const exprt &base)
1150-
{
1151-
return base.id() == ID_rem;
1152-
}
1153-
1154-
inline void validate_expr(const rem_exprt &value)
1155-
{
1156-
validate_operands(value, 2, "Remainder must have two operands");
1157-
}
1158-
1159-
/// \brief Cast an exprt to a \ref rem_exprt
1160-
///
1161-
/// \a expr must be known to be \ref rem_exprt.
1162-
///
1163-
/// \param expr: Source expression
1164-
/// \return Object of type \ref rem_exprt
1165-
inline const rem_exprt &to_rem_expr(const exprt &expr)
1166-
{
1167-
PRECONDITION(expr.id()==ID_rem);
1168-
const rem_exprt &ret = static_cast<const rem_exprt &>(expr);
1169-
validate_expr(ret);
1170-
return ret;
1171-
}
1172-
1173-
/// \copydoc to_rem_expr(const exprt &)
1174-
inline rem_exprt &to_rem_expr(exprt &expr)
1175-
{
1176-
PRECONDITION(expr.id()==ID_rem);
1177-
rem_exprt &ret = static_cast<rem_exprt &>(expr);
1178-
validate_expr(ret);
1179-
return ret;
1180-
}
1181-
11821138

11831139
/// \brief Equality
11841140
class equal_exprt:public binary_relation_exprt

0 commit comments

Comments
 (0)