The unused attribute lint is actually running earlier than it should right
now, which forces it to globally whitelist every attribute that's only used
in trans:
https://github.com/rust-lang/rust/blob/master/src/librustc/lint/builtin.rs#L563.
It can't know if an attribute is unused until we've given the compiler an
opportunity to use it!

Steven Fackler


On Wed, Jul 16, 2014 at 5:16 PM, Ben Harris <[email protected]> wrote:

> Have a quick skim over this (
> http://tomlee.co/2014/04/03/a-more-detailed-tour-of-the-rust-compiler/).
> Lint is the last thing to run before conversion to LLVM.
>
> I'f you like to suggest it changed or augmented, the rust-lang/rust issues
> board would be best.
>
>
> On 16 July 2014 23:15, Ilya Dmitrichenko <[email protected]> wrote:
>
>> On 16 July 2014 15:23, Chris Morgan <[email protected]> wrote:
>> >>> Did it come up as an unused-attribute warning?
>> >> No, it didn't.
>> > The simple reason it doesn't come up as an unknown attribute is
>> > because it did not successfully compile, and so it did not get to the
>> > step where it warns about unused attributes.
>>
>> Sure, it's pretty clear what's going on, but I do think it's a bit of
>> a problem. It's rather hard to spot a misspelled attribute. Should
>> there be a pre-lint stage for this purpose?
>> _______________________________________________
>> Rust-dev mailing list
>> [email protected]
>> https://mail.mozilla.org/listinfo/rust-dev
>>
>
>
> _______________________________________________
> Rust-dev mailing list
> [email protected]
> https://mail.mozilla.org/listinfo/rust-dev
>
>
_______________________________________________
Rust-dev mailing list
[email protected]
https://mail.mozilla.org/listinfo/rust-dev

Reply via email to