gccrs: HIR: remove obsole double borrow member

gcc/rust/ChangeLog:

	* hir/rust-hir-dump.cc (Dump::visit): Remove obsolete member.
	* hir/tree/rust-hir-expr.h (class BorrowExpr): Remove obsolete member.
	* hir/tree/rust-hir.cc (BorrowExpr::as_string): Remove obsolete member.

Signed-off-by: Jakub Dupak <dev@jakubdupak.com>
This commit is contained in:
Jakub Dupak 2023-11-02 13:42:48 +01:00 committed by Arthur Cohen
parent f61184ee8c
commit 80bdb1a85a
3 changed files with 0 additions and 9 deletions

View file

@ -808,7 +808,6 @@ Dump::visit (BorrowExpr &e)
begin ("BorrowExpr");
do_operatorexpr (e);
put_field ("double_borrow", std::to_string (e.is_double_borrow ()));
put_field ("mut", enum_to_str (e.get_mut ()));
end ("BorrowExpr");

View file

@ -213,7 +213,6 @@ public:
class BorrowExpr : public OperatorExpr
{
Mutability mut;
bool double_borrow;
public:
std::string as_string () const override;
@ -232,8 +231,6 @@ public:
Mutability get_mut () const { return mut; }
bool is_mut () const { return mut == Mutability::Mut; }
bool is_double_borrow () const { return double_borrow; }
protected:
/* Use covariance to implement clone function as returning this object rather
* than base */

View file

@ -1182,11 +1182,6 @@ BorrowExpr::as_string () const
{
std::string str ("&");
if (double_borrow)
{
str += "&";
}
if (is_mut ())
{
str += "mut ";