Compile error? attribute `phase` is currently unknown
Closed this issue · 2 comments
lenzj commented
I can get libhoare crate to compile successfully now, but when I try and use it in my application I'm getting the following error:
Compiling test v0.1.0 (file:///home/user/test)
src/lib.rs:5:1: 5:17 src/lib.rs:5:1: 5:17 error: The attribute `phase` is currently unknown to the compiler and may have meaning added to it in the future
error: src/lib.rs:5 #[phase(plugin)]
^~~~~~~~~~~~~~~~
src/lib.rs:5:1: 5:17 The attribute `phase` is currently unknown to the compiler and may have meaning added to it in the future
src/lib.rs:5 #[phase(plugin)]
^~~~~~~~~~~~~~~~
Below is what I put in my src/lib.rs
#![feature(phase)]
#[phase(plugin)]
extern crate hoare;
nrc commented
That has changed (in Rust), nowadays you need:
#![feature(plugin, custom_attribute)]
#![plugin(hoare)]
nrc commented
Thanks for persevering!