summaryrefslogtreecommitdiffstats
path: root/tests/ui-fulldeps/lint-plugin-forbid-attrs.rs
diff options
context:
space:
mode:
Diffstat (limited to 'tests/ui-fulldeps/lint-plugin-forbid-attrs.rs')
-rw-r--r--tests/ui-fulldeps/lint-plugin-forbid-attrs.rs16
1 files changed, 16 insertions, 0 deletions
diff --git a/tests/ui-fulldeps/lint-plugin-forbid-attrs.rs b/tests/ui-fulldeps/lint-plugin-forbid-attrs.rs
new file mode 100644
index 000000000..cf31b3ec1
--- /dev/null
+++ b/tests/ui-fulldeps/lint-plugin-forbid-attrs.rs
@@ -0,0 +1,16 @@
+// aux-build:lint-plugin-test.rs
+// ignore-stage1
+
+#![feature(plugin)]
+#![plugin(lint_plugin_test)]
+//~^ WARN use of deprecated attribute `plugin`
+#![forbid(test_lint)]
+
+fn lintme() {} //~ ERROR item is named 'lintme'
+
+#[allow(test_lint)]
+//~^ ERROR allow(test_lint) incompatible
+//~| ERROR allow(test_lint) incompatible
+pub fn main() {
+ lintme();
+}