aboutsummaryrefslogtreecommitdiff
path: root/gcc/rust/hir/rust-ast-lower-struct-field-expr.h
diff options
context:
space:
mode:
authorPhilip Herron <philip.herron@embecosm.com>2021-01-18 16:47:16 +0000
committerPhilip Herron <herron.philip@googlemail.com>2021-01-20 09:59:22 +0000
commit6e2acd529fcfa43368f7ea8209cc5e6b88d2bd79 (patch)
treebe47967ba0e8db1ab76d7688ecb29de40d3ccbc5 /gcc/rust/hir/rust-ast-lower-struct-field-expr.h
parentf8d41b7e8a3a65382dc5ce30dfb3f85abe298d19 (diff)
downloadgcc-6e2acd529fcfa43368f7ea8209cc5e6b88d2bd79.zip
gcc-6e2acd529fcfa43368f7ea8209cc5e6b88d2bd79.tar.gz
gcc-6e2acd529fcfa43368f7ea8209cc5e6b88d2bd79.tar.bz2
Support Struct field index initialisation
For TupleStructs the constructor can take field indexes to support change or ordering of the fields.
Diffstat (limited to 'gcc/rust/hir/rust-ast-lower-struct-field-expr.h')
-rw-r--r--gcc/rust/hir/rust-ast-lower-struct-field-expr.h2
1 files changed, 2 insertions, 0 deletions
diff --git a/gcc/rust/hir/rust-ast-lower-struct-field-expr.h b/gcc/rust/hir/rust-ast-lower-struct-field-expr.h
index 1b444a5..71c1f1f 100644
--- a/gcc/rust/hir/rust-ast-lower-struct-field-expr.h
+++ b/gcc/rust/hir/rust-ast-lower-struct-field-expr.h
@@ -46,6 +46,8 @@ public:
void visit (AST::StructExprFieldIdentifierValue &field);
+ void visit (AST::StructExprFieldIndexValue &field);
+
private:
ASTLowerStructExprField () : translated (nullptr) {}