aboutsummaryrefslogtreecommitdiff
path: root/gcc/rust/resolve/rust-ast-resolve-implitem.h
diff options
context:
space:
mode:
authorPhilip Herron <philip.herron@embecosm.com>2022-02-02 15:05:19 +0000
committerPhilip Herron <philip.herron@embecosm.com>2022-02-02 16:47:19 +0000
commit4d1ca35582e69e8677bd96775edbf03b6eec6ab8 (patch)
tree4baa7da3f520efec9d02c4d0c44a8b07268a6f5d /gcc/rust/resolve/rust-ast-resolve-implitem.h
parentf7f14de056eb3887e70f29b0f29da4025f746559 (diff)
downloadgcc-4d1ca35582e69e8677bd96775edbf03b6eec6ab8.zip
gcc-4d1ca35582e69e8677bd96775edbf03b6eec6ab8.tar.gz
gcc-4d1ca35582e69e8677bd96775edbf03b6eec6ab8.tar.bz2
Apply the is_marked_for_strip check to the rest of the crate
We need to apply this to all levels of the crate: Item impl-item trait-item Stmt
Diffstat (limited to 'gcc/rust/resolve/rust-ast-resolve-implitem.h')
-rw-r--r--gcc/rust/resolve/rust-ast-resolve-implitem.h6
1 files changed, 6 insertions, 0 deletions
diff --git a/gcc/rust/resolve/rust-ast-resolve-implitem.h b/gcc/rust/resolve/rust-ast-resolve-implitem.h
index 074855e..f17b222 100644
--- a/gcc/rust/resolve/rust-ast-resolve-implitem.h
+++ b/gcc/rust/resolve/rust-ast-resolve-implitem.h
@@ -33,12 +33,18 @@ class ResolveToplevelImplItem : public ResolverBase
public:
static void go (AST::InherentImplItem *item, const CanonicalPath &prefix)
{
+ if (item->is_marked_for_strip ())
+ return;
+
ResolveToplevelImplItem resolver (prefix);
item->accept_vis (resolver);
}
static void go (AST::TraitImplItem *item, const CanonicalPath &prefix)
{
+ if (item->is_marked_for_strip ())
+ return;
+
ResolveToplevelImplItem resolver (prefix);
item->accept_vis (resolver);
}