aboutsummaryrefslogtreecommitdiff
path: root/gcc
diff options
context:
space:
mode:
authorDavid Faust <david.faust@oracle.com>2022-10-13 10:23:44 -0700
committerDavid Faust <david.faust@oracle.com>2022-10-13 13:35:56 -0700
commitd27cb6e12827b9a0d7ac024f15e3aa04650083c9 (patch)
treecc93875c00aa743e6663d6ddbc13f819b6cd4acc /gcc
parent53e2df36a23e6f1ec820c5ef51bb07842c2ba0b7 (diff)
downloadgcc-d27cb6e12827b9a0d7ac024f15e3aa04650083c9.zip
gcc-d27cb6e12827b9a0d7ac024f15e3aa04650083c9.tar.gz
gcc-d27cb6e12827b9a0d7ac024f15e3aa04650083c9.tar.bz2
ast: dump: RangeExprs
Diffstat (limited to 'gcc')
-rw-r--r--gcc/rust/ast/rust-ast-dump.cc31
1 files changed, 25 insertions, 6 deletions
diff --git a/gcc/rust/ast/rust-ast-dump.cc b/gcc/rust/ast/rust-ast-dump.cc
index b9e08b5..8caad98 100644
--- a/gcc/rust/ast/rust-ast-dump.cc
+++ b/gcc/rust/ast/rust-ast-dump.cc
@@ -622,27 +622,46 @@ Dump::visit (BreakExpr &expr)
void
Dump::visit (RangeFromToExpr &expr)
-{}
+{
+ expr.get_from_expr ()->accept_vis (*this);
+ stream << "..";
+ expr.get_to_expr ()->accept_vis (*this);
+}
void
Dump::visit (RangeFromExpr &expr)
-{}
+{
+ expr.get_from_expr ()->accept_vis (*this);
+ stream << "..";
+}
void
Dump::visit (RangeToExpr &expr)
-{}
+{
+ stream << "..";
+ expr.get_to_expr ()->accept_vis (*this);
+}
void
Dump::visit (RangeFullExpr &expr)
-{}
+{
+ stream << "..";
+}
void
Dump::visit (RangeFromToInclExpr &expr)
-{}
+{
+ expr.get_from_expr ()->accept_vis (*this);
+ stream << "..=";
+ expr.get_to_expr ()->accept_vis (*this);
+}
void
Dump::visit (RangeToInclExpr &expr)
-{}
+{
+ stream << "..=";
+ expr.get_to_expr ()->accept_vis (*this);
+}
void
Dump::visit (ReturnExpr &expr)