summaryrefslogtreecommitdiffstats
path: root/src/tools/clippy/tests/ui/four_forward_slashes.rs
diff options
context:
space:
mode:
Diffstat (limited to 'src/tools/clippy/tests/ui/four_forward_slashes.rs')
-rw-r--r--src/tools/clippy/tests/ui/four_forward_slashes.rs48
1 files changed, 48 insertions, 0 deletions
diff --git a/src/tools/clippy/tests/ui/four_forward_slashes.rs b/src/tools/clippy/tests/ui/four_forward_slashes.rs
new file mode 100644
index 000000000..facdc8cb1
--- /dev/null
+++ b/src/tools/clippy/tests/ui/four_forward_slashes.rs
@@ -0,0 +1,48 @@
+//@run-rustfix
+//@aux-build:proc_macros.rs:proc-macro
+#![feature(custom_inner_attributes)]
+#![allow(unused)]
+#![warn(clippy::four_forward_slashes)]
+#![no_main]
+#![rustfmt::skip]
+
+#[macro_use]
+extern crate proc_macros;
+
+//// whoops
+fn a() {}
+
+//// whoops
+#[allow(dead_code)]
+fn b() {}
+
+//// whoops
+//// two borked comments!
+#[track_caller]
+fn c() {}
+
+fn d() {}
+
+#[test]
+//// between attributes
+#[allow(dead_code)]
+fn g() {}
+
+ //// not very start of contents
+fn h() {}
+
+fn i() {
+ //// don't lint me bozo
+ todo!()
+}
+
+external! {
+ //// don't lint me bozo
+ fn e() {}
+}
+
+with_span! {
+ span
+ //// don't lint me bozo
+ fn f() {}
+}