projects
/
platform
/
upstream
/
gcc.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
93fcadd
)
gccrs: Add get_item method for HIR::GroupedPattern
author
Owen Avery
<powerboat9.gamer@gmail.com>
Wed, 25 Jan 2023 18:00:38 +0000
(13:00 -0500)
committer
Arthur Cohen
<arthur.cohen@embecosm.com>
Thu, 6 Apr 2023 08:47:18 +0000
(10:47 +0200)
gcc/rust/ChangeLog:
* hir/tree/rust-hir-pattern.h: Add get_item method.
Signed-off-by: Owen Avery <powerboat9.gamer@gmail.com>
gcc/rust/hir/tree/rust-hir-pattern.h
patch
|
blob
|
history
diff --git
a/gcc/rust/hir/tree/rust-hir-pattern.h
b/gcc/rust/hir/tree/rust-hir-pattern.h
index 80fa9b791a7d0e016706fa3763192a688efaa58a..b7a230c526f5118eb4cabf9f2d6c15f46724f1ef 100644
(file)
--- a/
gcc/rust/hir/tree/rust-hir-pattern.h
+++ b/
gcc/rust/hir/tree/rust-hir-pattern.h
@@
-1269,6
+1269,12
@@
public:
return PatternType::GROUPED;
}
+ std::unique_ptr<Pattern> &get_item () { return pattern_in_parens; }
+ const std::unique_ptr<Pattern> &get_item () const
+ {
+ return pattern_in_parens;
+ }
+
protected:
/* Use covariance to implement clone function as returning this object rather
* than base */