aboutsummaryrefslogtreecommitdiff
path: root/gcc/rust/hir/tree/rust-hir-item.h
diff options
context:
space:
mode:
Diffstat (limited to 'gcc/rust/hir/tree/rust-hir-item.h')
-rw-r--r--gcc/rust/hir/tree/rust-hir-item.h5
1 files changed, 5 insertions, 0 deletions
diff --git a/gcc/rust/hir/tree/rust-hir-item.h b/gcc/rust/hir/tree/rust-hir-item.h
index 13e933b..c719a7b 100644
--- a/gcc/rust/hir/tree/rust-hir-item.h
+++ b/gcc/rust/hir/tree/rust-hir-item.h
@@ -1965,6 +1965,7 @@ public:
}
std::vector<std::unique_ptr<EnumItem>> &get_variants () { return items; }
+ WhereClause &get_where_clause () { return where_clause; }
protected:
/* Use covariance to implement clone function as returning this object
@@ -2638,7 +2639,10 @@ public:
return trait_items;
}
+ WhereClause &get_where_clause () { return where_clause; }
+
Identifier get_name () const { return name; }
+ bool is_unsafe () const { return unsafety == Unsafety::Unsafe; }
// Mega-constructor
Trait (Analysis::NodeMapping mappings, Identifier name, Unsafety unsafety,
@@ -2894,6 +2898,7 @@ public:
virtual void accept_vis (HIRFullVisitor &vis) = 0;
virtual void accept_vis (HIRExternalItemVisitor &vis) = 0;
+ Visibility &get_visibility () { return visibility; }
Analysis::NodeMapping get_mappings () const { return mappings; }
Identifier get_item_name () const { return item_name; }