-
Couldn't load subscription status.
- Fork 55
Open
Description
There are two styles of empty match arms prevalent in Rust code:
match x {
a => {} // Option A
b => () // Option B
}The preferred option should be specified by the style guide (and correspondingly enforced by rustfmt). For reference, rustc currently uses a mixture, but with a bias towards Option A.
https://github.com/rust-dev-tools/fmt-rfcs/blob/master/guide/expressions.md#match doesn't mention this issue, though one of the examples does show an arm using Option A.
iago-lito
Metadata
Metadata
Assignees
Labels
No labels