diff --git a/src/test/rustdoc-ui/issue-106226.rs b/src/test/rustdoc-ui/issue-106226.rs new file mode 100644 index 00000000000..71b497a9adc --- /dev/null +++ b/src/test/rustdoc-ui/issue-106226.rs @@ -0,0 +1,3 @@ +// This is a regression test for . +type F = [_; ()]; +//~^ ERROR diff --git a/src/test/rustdoc-ui/issue-106226.stderr b/src/test/rustdoc-ui/issue-106226.stderr new file mode 100644 index 00000000000..2beffbc125b --- /dev/null +++ b/src/test/rustdoc-ui/issue-106226.stderr @@ -0,0 +1,9 @@ +error[E0308]: mismatched types + --> $DIR/issue-106226.rs:2:14 + | +LL | type F = [_; ()]; + | ^^ expected `usize`, found `()` + +error: aborting due to previous error + +For more information about this error, try `rustc --explain E0308`.