diff options
author | Pierre-Emmanuel Patry <pierre-emmanuel.patry@embecosm.com> | 2023-03-30 20:05:14 +0200 |
---|---|---|
committer | CohenArthur <arthur.cohen@embecosm.com> | 2023-04-05 08:20:48 +0000 |
commit | 6ad6a78a4ae42358e1f2cbd36f26740ae05e2146 (patch) | |
tree | 5967e9b98ca90551b4cbc7a59af9c6f278b5ea3a /gcc/rust/backend/rust-compile-block.h | |
parent | fe11b51bd316141618b41292e74b4439b02860ac (diff) | |
download | gcc-6ad6a78a4ae42358e1f2cbd36f26740ae05e2146.zip gcc-6ad6a78a4ae42358e1f2cbd36f26740ae05e2146.tar.gz gcc-6ad6a78a4ae42358e1f2cbd36f26740ae05e2146.tar.bz2 |
ast: Add outer attribute getter to Expr class
We need to retrieve outer attributes from some Expressions depending on
their context. This means this should be retrieved from their parent
node. But expr did not have a getter for outer attributes since some
expr can't have any outer attribute.
gcc/rust/ChangeLog:
* ast/rust-ast.h: Add getter to Expr class.
* ast/rust-expr.h: Add override attribute to existing getters.
Also implement it for RangeExpr, attempting to retrieve outer
attributes on those types will crash the compiler.
* ast/rust-macro.h: Add override attribute to existing getters.
* ast/rust-path.h: Likewise.
Signed-off-by: Pierre-Emmanuel Patry <pierre-emmanuel.patry@embecosm.com>
Diffstat (limited to 'gcc/rust/backend/rust-compile-block.h')
0 files changed, 0 insertions, 0 deletions