Skip to content

Remove slice pattern from compiler plugin example #29951

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

Merged
merged 1 commit into from
Nov 20, 2015

Conversation

fhahn
Copy link
Contributor

@fhahn fhahn commented Nov 20, 2015

PR for #29930. Adds missing #![feature(slice_patterns)] to make compiler plugin example compile again.

@rust-highfive
Copy link
Contributor

r? @nikomatsakis

(rust_highfive has picked a reviewer for you, use r? to override)

@arielb1
Copy link
Contributor

arielb1 commented Nov 20, 2015

I would prefer to remove the slice pattern - slice patterns are dangerous.

@fhahn fhahn force-pushed the fix-plugin-compiler-example branch from c8ebfaa to c53722d Compare November 20, 2015 13:31
@fhahn
Copy link
Contributor Author

fhahn commented Nov 20, 2015

Sure, I've updated the commit though I am not sure if there is a nicer way to replace the slice pattern.

I also noticed that src/test/auxiliary/roman_numerals.rs and the example in the book used different integer types (one used usize and one u32), my commit also updates the example to use usize as well. I hope that's OK. If not I would be happy to update the PR again.

@fhahn fhahn changed the title Add #![feature(slice_patterns)] to compiler plugin example Remove slice pattern from compiler plugin example Nov 20, 2015
@steveklabnik
Copy link
Member

@bors: r+ rollup

@bors
Copy link
Collaborator

bors commented Nov 20, 2015

📌 Commit c53722d has been approved by steveklabnik

@steveklabnik
Copy link
Member

Thanks!

@bors
Copy link
Collaborator

bors commented Nov 20, 2015

⌛ Testing commit c53722d with merge 6827661...

bors added a commit that referenced this pull request Nov 20, 2015
PR for #29930. Adds missing #![feature(slice_patterns)] to make compiler plugin example compile again.
@bors bors merged commit c53722d into rust-lang:master Nov 20, 2015
@fhahn fhahn deleted the fix-plugin-compiler-example branch November 20, 2015 21:17
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.

6 participants