aboutsummaryrefslogtreecommitdiffstats
path: root/tests/compiletest/plugin/compile-fail/privatize.rs
diff options
context:
space:
mode:
authorAnthony Ramine <n.oxyde@gmail.com>2017-02-14 17:35:39 +0100
committerAnthony Ramine <n.oxyde@gmail.com>2017-02-15 10:24:01 +0100
commit8bcf36b9a59b4f30fd54fceb85eeb51b1d4dee4f (patch)
tree16f762e408981f2130095470fc4c7b868f9011c2 /tests/compiletest/plugin/compile-fail/privatize.rs
parent19c645ff68f517929308d1f22728d72231e9a543 (diff)
downloadservo-8bcf36b9a59b4f30fd54fceb85eeb51b1d4dee4f.tar.gz
servo-8bcf36b9a59b4f30fd54fceb85eeb51b1d4dee4f.zip
Change #[privatize] into #[derive(DenyPublicFields)]
Diffstat (limited to 'tests/compiletest/plugin/compile-fail/privatize.rs')
-rw-r--r--tests/compiletest/plugin/compile-fail/privatize.rs9
1 files changed, 5 insertions, 4 deletions
diff --git a/tests/compiletest/plugin/compile-fail/privatize.rs b/tests/compiletest/plugin/compile-fail/privatize.rs
index a6f2ffdbe62..ef185c2169c 100644
--- a/tests/compiletest/plugin/compile-fail/privatize.rs
+++ b/tests/compiletest/plugin/compile-fail/privatize.rs
@@ -2,14 +2,15 @@
* License, v. 2.0. If a copy of the MPL was not distributed with this
* file, You can obtain one at http://mozilla.org/MPL/2.0/. */
-#![feature(plugin, custom_attribute)]
-#![plugin(plugins)]
#![allow(dead_code)]
-#[privatize]
+#[macro_use]
+extern crate deny_public_fields;
+
+#[derive(DenyPublicFields)]
+//~^ ERROR custom derive attribute panicked
struct Foo {
pub v1: i32,
- //~^ ERROR Field v1 is public where only private fields are allowed
v2: i32
}