summaryrefslogtreecommitdiffstats
path: root/tests/ui/lint/issue-109152.rs
diff options
context:
space:
mode:
Diffstat (limited to '')
-rw-r--r--tests/ui/lint/issue-109152.rs7
1 files changed, 7 insertions, 0 deletions
diff --git a/tests/ui/lint/issue-109152.rs b/tests/ui/lint/issue-109152.rs
new file mode 100644
index 000000000..daf530e6d
--- /dev/null
+++ b/tests/ui/lint/issue-109152.rs
@@ -0,0 +1,7 @@
+#![deny(map_unit_fn)]
+
+#![crate_type = "lib"]
+fn _y() {
+ vec![42].iter().map(drop);
+ //~^ ERROR `Iterator::map` call that discard the iterator's values
+}