summaryrefslogtreecommitdiff
path: root/src/dump_as_rust.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'src/dump_as_rust.cpp')
-rw-r--r--src/dump_as_rust.cpp8
1 files changed, 5 insertions, 3 deletions
diff --git a/src/dump_as_rust.cpp b/src/dump_as_rust.cpp
index 4091842a..2d079223 100644
--- a/src/dump_as_rust.cpp
+++ b/src/dump_as_rust.cpp
@@ -808,15 +808,17 @@ void RustPrinter::print_pattern(const AST::Pattern& p, bool is_refutable)
m_os << " ... " << v.end;
}
),
- (StructTuple, {
- const auto& v = p.data().as_StructTuple();
+ (WildcardStructTuple,
+ m_os << v.path << "(..)";
+ ),
+ (StructTuple,
m_os << v.path << "(";
for(const auto& sp : v.sub_patterns) {
print_pattern(sp, is_refutable);
m_os << ",";
}
m_os << ")";
- }),
+ ),
(Struct, {
const auto& v = p.data().as_Struct();
m_os << v.path << "(";