diff options
Diffstat (limited to 'gcc/rust/resolve')
-rw-r--r-- | gcc/rust/resolve/rust-ast-resolve-base.h | 1 | ||||
-rw-r--r-- | gcc/rust/resolve/rust-ast-resolve-implitem.h | 15 | ||||
-rw-r--r-- | gcc/rust/resolve/rust-ast-resolve-item.h | 10 | ||||
-rw-r--r-- | gcc/rust/resolve/rust-ast-resolve-stmt.h | 5 | ||||
-rw-r--r-- | gcc/rust/resolve/rust-ast-resolve-toplevel.h | 2 |
5 files changed, 25 insertions, 8 deletions
diff --git a/gcc/rust/resolve/rust-ast-resolve-base.h b/gcc/rust/resolve/rust-ast-resolve-base.h index 6ee5f3d..eca9694 100644 --- a/gcc/rust/resolve/rust-ast-resolve-base.h +++ b/gcc/rust/resolve/rust-ast-resolve-base.h @@ -38,7 +38,6 @@ public: void visit (AST::IdentifierExpr &) {} void visit (AST::Lifetime &) {} void visit (AST::LifetimeParam &) {} - void visit (AST::MacroInvocationSemi &) {} void visit (AST::PathInExpression &) {} void visit (AST::TypePathSegment &) {} void visit (AST::TypePathSegmentGeneric &) {} diff --git a/gcc/rust/resolve/rust-ast-resolve-implitem.h b/gcc/rust/resolve/rust-ast-resolve-implitem.h index ce7234c..7393393 100644 --- a/gcc/rust/resolve/rust-ast-resolve-implitem.h +++ b/gcc/rust/resolve/rust-ast-resolve-implitem.h @@ -49,8 +49,11 @@ public: item->accept_vis (resolver); } - void visit (AST::MacroInvocationSemi &invoc) override + void visit (AST::MacroInvocation &invoc) override { + if (!invoc.has_semicolon ()) + return; + AST::ASTFragment &fragment = invoc.get_fragment (); for (auto &node : fragment.get_nodes ()) node.accept_vis (*this); @@ -144,8 +147,11 @@ public: item->accept_vis (resolver); }; - void visit (AST::MacroInvocationSemi &invoc) override + void visit (AST::MacroInvocation &invoc) override { + if (!invoc.has_semicolon ()) + return; + AST::ASTFragment &fragment = invoc.get_fragment (); for (auto &node : fragment.get_nodes ()) node.accept_vis (*this); @@ -254,8 +260,11 @@ public: item->accept_vis (resolver); }; - void visit (AST::MacroInvocationSemi &invoc) override + void visit (AST::MacroInvocation &invoc) override { + if (!invoc.has_semicolon ()) + return; + AST::ASTFragment &fragment = invoc.get_fragment (); for (auto &node : fragment.get_nodes ()) node.accept_vis (*this); diff --git a/gcc/rust/resolve/rust-ast-resolve-item.h b/gcc/rust/resolve/rust-ast-resolve-item.h index 48f93e5..2cb0006 100644 --- a/gcc/rust/resolve/rust-ast-resolve-item.h +++ b/gcc/rust/resolve/rust-ast-resolve-item.h @@ -45,8 +45,11 @@ public: item->accept_vis (resolver); }; - void visit (AST::MacroInvocationSemi &invoc) override + void visit (AST::MacroInvocation &invoc) override { + if (!invoc.has_semicolon ()) + return; + AST::ASTFragment &fragment = invoc.get_fragment (); for (auto &node : fragment.get_nodes ()) node.accept_vis (*this); @@ -234,8 +237,11 @@ public: item->accept_vis (resolver); }; - void visit (AST::MacroInvocationSemi &invoc) override + void visit (AST::MacroInvocation &invoc) override { + if (!invoc.has_semicolon ()) + return; + AST::ASTFragment &fragment = invoc.get_fragment (); for (auto &node : fragment.get_nodes ()) node.accept_vis (*this); diff --git a/gcc/rust/resolve/rust-ast-resolve-stmt.h b/gcc/rust/resolve/rust-ast-resolve-stmt.h index 7521739..785f3de 100644 --- a/gcc/rust/resolve/rust-ast-resolve-stmt.h +++ b/gcc/rust/resolve/rust-ast-resolve-stmt.h @@ -44,8 +44,11 @@ public: stmt->accept_vis (resolver); }; - void visit (AST::MacroInvocationSemi &invoc) override + void visit (AST::MacroInvocation &invoc) override { + if (!invoc.has_semicolon ()) + return; + AST::ASTFragment &fragment = invoc.get_fragment (); for (auto &node : fragment.get_nodes ()) diff --git a/gcc/rust/resolve/rust-ast-resolve-toplevel.h b/gcc/rust/resolve/rust-ast-resolve-toplevel.h index 39d6818..1f528fe 100644 --- a/gcc/rust/resolve/rust-ast-resolve-toplevel.h +++ b/gcc/rust/resolve/rust-ast-resolve-toplevel.h @@ -43,7 +43,7 @@ public: item->accept_vis (resolver); }; - void visit (AST::MacroInvocationSemi &invoc) override + void visit (AST::MacroInvocation &invoc) override { AST::ASTFragment &fragment = invoc.get_fragment (); for (auto &node : fragment.get_nodes ()) |