aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorJakub Dupak <dev@jakubdupak.com>2022-11-06 20:49:17 +0100
committerJakub Dupak <dev@jakubdupak.com>2022-11-16 16:26:44 +0100
commitf4d78133368ff453eaf60413c697cf848ad1e17e (patch)
tree4df3c7a4abe4f3a1159625b9793d5a168bddfe2a
parent27136db8fd7b428870f6c85ae4b328f54c8de4bb (diff)
downloadgcc-f4d78133368ff453eaf60413c697cf848ad1e17e.zip
gcc-f4d78133368ff453eaf60413c697cf848ad1e17e.tar.gz
gcc-f4d78133368ff453eaf60413c697cf848ad1e17e.tar.bz2
ast: Dump slice type
Signed-off-by: Jakub Dupak <dev@jakubdupak.com>
-rw-r--r--gcc/rust/ast/rust-ast-dump.cc5
1 files changed, 5 insertions, 0 deletions
diff --git a/gcc/rust/ast/rust-ast-dump.cc b/gcc/rust/ast/rust-ast-dump.cc
index 8e2a8c6..3f5dada 100644
--- a/gcc/rust/ast/rust-ast-dump.cc
+++ b/gcc/rust/ast/rust-ast-dump.cc
@@ -1606,7 +1606,12 @@ Dump::visit (ArrayType &type)
void
Dump::visit (SliceType &type)
{
+ // Syntax:
+ // [ Type ]
+
+ stream << '[';
visit (type.get_elem_type ());
+ stream << ']';
}
void