From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: by sourceware.org (Postfix, from userid 1643) id 0E620384F6D5; Fri, 18 Nov 2022 23:34:10 +0000 (GMT) DKIM-Filter: OpenDKIM Filter v2.11.0 sourceware.org 0E620384F6D5 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gcc.gnu.org; s=default; t=1668814450; bh=yk7BcklfEA9slJ+qYjefktKGEpn0PD2Zh3+U8bJu+AQ=; h=From:To:Subject:Date:From; b=cdFum8DGCdlIe+/Du0Uq2NcWTDOWHJy0o56rgn7d5Ls7Sb4As0K23wp0ONT9xavHE 84AW1pNGZYNo5tTbv/3OPRXx0gr15AjpJ8GKl3AgRGs9MQvRNR8cLks/6hThiDoe5h 1vhbnyivdG7BWe+69vQXIz2xL4fBMZT2MYTVXi7k= Content-Type: text/plain; charset="us-ascii" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit From: Thomas Schwinge To: gcc-cvs@gcc.gnu.org Subject: [gcc/devel/rust/master] ast: Dump parenthesised type X-Act-Checkin: gcc X-Git-Author: Jakub Dupak X-Git-Refname: refs/heads/devel/rust/master X-Git-Oldrev: 0e026b6c33d20a7d1b8714df73e9157ede98af70 X-Git-Newrev: 4c69451b3d46db438a5c2cc436f7b02dbf4bbab2 Message-Id: <20221118233410.0E620384F6D5@sourceware.org> Date: Fri, 18 Nov 2022 23:34:10 +0000 (GMT) List-Id: https://gcc.gnu.org/g:4c69451b3d46db438a5c2cc436f7b02dbf4bbab2 commit 4c69451b3d46db438a5c2cc436f7b02dbf4bbab2 Author: Jakub Dupak Date: Tue Nov 15 15:52:34 2022 +0100 ast: Dump parenthesised type Signed-off-by: Jakub Dupak Diff: --- gcc/rust/ast/rust-ast-dump.cc | 11 +++++++++-- 1 file changed, 9 insertions(+), 2 deletions(-) diff --git a/gcc/rust/ast/rust-ast-dump.cc b/gcc/rust/ast/rust-ast-dump.cc index 0ae57fdb744..8e06bf38a6a 100644 --- a/gcc/rust/ast/rust-ast-dump.cc +++ b/gcc/rust/ast/rust-ast-dump.cc @@ -1635,8 +1635,15 @@ Dump::visit (TraitObjectType &type) } void -Dump::visit (ParenthesisedType &) -{} +Dump::visit (ParenthesisedType &type) +{ + // Syntax: + // ( Type ) + + stream << "("; + visit (type.get_type_in_parens ()); + stream << ")"; +} void Dump::visit (ImplTraitTypeOneBound &type)