about summary refs log tree commit diff
path: root/compiler/rustc_pattern_analysis/src/rustc.rs
diff options
context:
space:
mode:
authorZalathar <Zalathar@users.noreply.github.com>2024-08-03 20:48:52 +1000
committerZalathar <Zalathar@users.noreply.github.com>2024-08-11 19:57:30 +1000
commit15cc0e1b5cb9cc84ce017b656a75d9954f394f03 (patch)
treec3175395c6257de9ebe2b56a03d253de0a206563 /compiler/rustc_pattern_analysis/src/rustc.rs
parented3e38f33697efd2272b2df6a31b450e1e6ee12b (diff)
downloadrust-15cc0e1b5cb9cc84ce017b656a75d9954f394f03.tar.gz
rust-15cc0e1b5cb9cc84ce017b656a75d9954f394f03.zip
Remove `PatKind::Box`
Diffstat (limited to 'compiler/rustc_pattern_analysis/src/rustc.rs')
-rw-r--r--compiler/rustc_pattern_analysis/src/rustc.rs2
1 files changed, 1 insertions, 1 deletions
diff --git a/compiler/rustc_pattern_analysis/src/rustc.rs b/compiler/rustc_pattern_analysis/src/rustc.rs
index 1d687cc1065..91650c7531a 100644
--- a/compiler/rustc_pattern_analysis/src/rustc.rs
+++ b/compiler/rustc_pattern_analysis/src/rustc.rs
@@ -832,7 +832,7 @@ impl<'p, 'tcx: 'p> RustcPatCtxt<'p, 'tcx> {
             Struct if pat.ty().is_box() => {
                 // Outside of the `alloc` crate, the only way to create a struct pattern
                 // of type `Box` is to use a `box` pattern via #[feature(box_patterns)].
-                PatKind::Box { subpattern: hoist(&pat.fields[0]) }
+                PatKind::Print(format!("box {}", hoist(&pat.fields[0])))
             }
             Struct | Variant(_) | UnionField => {
                 let enum_info = match *pat.ty().kind() {