Skip to content

Conversation

steveklabnik
Copy link
Contributor

Fixes #4417.

then with `match` statements. Let's go on a whirlwind tour of all of the things
patterns can do!

A quick refresher: you can match against literals directly, and `_` as an 'any'
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

" and _ acts as an 'any' "

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks!

@steveklabnik
Copy link
Contributor Author

Rebased so this can actually get merged.

bors added a commit that referenced this pull request Aug 20, 2014
@bors bors closed this Aug 20, 2014
@bors bors merged commit ee3f074 into rust-lang:master Aug 20, 2014
@steveklabnik steveklabnik deleted the guide_patterns branch October 25, 2017 18:26
lnicola pushed a commit to lnicola/rust that referenced this pull request Apr 20, 2024
internal: Teach cargo about `cfg(rust_analyzer)`

r? `@Urgau` is this a good idea?, CC `@Veykril`
lnicola pushed a commit to lnicola/rust that referenced this pull request Apr 20, 2024
internal: Teach cargo about `cfg(rust_analyzer)`

r? `@Urgau` is this a good idea?, CC `@Veykril`
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.

tutorial: Compare closure argument patterns to match statements
6 participants