From 08c2c0e02b13a16cdac47a69ec952a46f9670886 Mon Sep 17 00:00:00 2001 From: Pierre-Emmanuel Patry Date: Thu, 23 Mar 2023 19:30:51 +0100 Subject: ast: Add AltPattern TokenStream visitor Add TokenStream visitor implementation for AltPattern. gcc/rust/ChangeLog: * ast/rust-ast-tokenstream.cc (TokenStream::visit): Add visitor. Signed-off-by: Pierre-Emmanuel Patry --- gcc/rust/ast/rust-ast-tokenstream.cc | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) (limited to 'gcc/rust/ast/rust-ast-tokenstream.cc') diff --git a/gcc/rust/ast/rust-ast-tokenstream.cc b/gcc/rust/ast/rust-ast-tokenstream.cc index 1bc1cab..ca64dd2 100644 --- a/gcc/rust/ast/rust-ast-tokenstream.cc +++ b/gcc/rust/ast/rust-ast-tokenstream.cc @@ -2525,8 +2525,10 @@ TokenStream::visit (SlicePattern &pattern) } void -TokenStream::visit (AltPattern &) -{} +TokenStream::visit (AltPattern &pattern) +{ + visit_items_as_lines (pattern.get_alts ()); +} // rust-stmt.h void -- cgit v1.1