aboutsummaryrefslogtreecommitdiff
path: root/gcc/rust/resolve/rust-ast-resolve-expr.cc
diff options
context:
space:
mode:
authorbors[bot] <26634292+bors[bot]@users.noreply.github.com>2022-03-11 08:24:43 +0000
committerGitHub <noreply@github.com>2022-03-11 08:24:43 +0000
commit51c7cf4b974140d4ace6c3cb79de9a00bb2efcbb (patch)
tree2df4325c6d707f4c49bffcd1497b647fc9d49fab /gcc/rust/resolve/rust-ast-resolve-expr.cc
parent77a49507446b67a6c207b4e4fec3639f536b9eca (diff)
parentf02392c8b378a68fb2525098a41a90bd16faa7fd (diff)
downloadgcc-51c7cf4b974140d4ace6c3cb79de9a00bb2efcbb.zip
gcc-51c7cf4b974140d4ace6c3cb79de9a00bb2efcbb.tar.gz
gcc-51c7cf4b974140d4ace6c3cb79de9a00bb2efcbb.tar.bz2
Merge #998
998: Parse macro expansion properly r=CohenArthur a=CohenArthur This PR adds a base for trying to parse statements or items in macro invocations. We are now able to parse multiple items / expressions / statements properly, but do not lower them properly, which is the last remaining task in #943 New macro parsing logic: ```mermaid flowchart TD; has_semi -- Yes --> stmt; has_semi -- No --> invocation; invocation -- Is Parens --> expr; invocation -- Is Square --> expr; invocation -- Is Curly --> stmt; ``` Closes #943 Closes #959 Closes #952 Co-authored-by: Arthur Cohen <arthur.cohen@embecosm.com>
Diffstat (limited to 'gcc/rust/resolve/rust-ast-resolve-expr.cc')
-rw-r--r--gcc/rust/resolve/rust-ast-resolve-expr.cc8
1 files changed, 0 insertions, 8 deletions
diff --git a/gcc/rust/resolve/rust-ast-resolve-expr.cc b/gcc/rust/resolve/rust-ast-resolve-expr.cc
index 19f8169..e551802 100644
--- a/gcc/rust/resolve/rust-ast-resolve-expr.cc
+++ b/gcc/rust/resolve/rust-ast-resolve-expr.cc
@@ -35,14 +35,6 @@ ResolveExpr::go (AST::Expr *expr, NodeId parent, const CanonicalPath &prefix,
}
void
-ResolveExpr::visit (AST::MacroInvocation &expr)
-{
- AST::ASTFragment &fragment = expr.get_fragment ();
- for (auto &node : fragment.get_nodes ())
- node.accept_vis (*this);
-}
-
-void
ResolveExpr::visit (AST::TupleIndexExpr &expr)
{
resolve_expr (expr.get_tuple_expr ().get (), expr.get_node_id ());