Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add deprecated attribute. #4144

Merged
merged 2 commits into from
Dec 11, 2012

Conversation

luqmana
Copy link
Member

@luqmana luqmana commented Dec 9, 2012

#723 - Add a deprecated items check to lint.

#[deprecated]
fn foo() {
    ...
}

#[deprecated = "use blah instead"]
fn bar() {
    ...
}

@catamorphism
Copy link
Contributor

Can you include a test case (or two) testing what the attribute you've added? Thanks!

catamorphism added a commit that referenced this pull request Dec 11, 2012
@catamorphism catamorphism merged commit f675b97 into rust-lang:incoming Dec 11, 2012
@catamorphism
Copy link
Contributor

Merged, thanks!

catamorphism added a commit that referenced this pull request Dec 11, 2012
This reverts commit f675b97, reversing
changes made to e7dd3af.
@catamorphism
Copy link
Contributor

Sorry, I had to back this out. It's not quite doing the right thing: you want to be checking for uses of deprecated items. Also, the test case didn't have an error pattern (look for //~ ERROR in existing compile-fail tests for examples of that). My fault for not looking at this more carefully. Feel free to submit an improved patch (or ask for advice on IRC).

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

2 participants