Skip to content

Commit 1973b90

Browse files
Comments
1 parent 922e8ba commit 1973b90

File tree

1 file changed

+6
-0
lines changed

1 file changed

+6
-0
lines changed

src/config/options.rs

+6
Original file line numberDiff line numberDiff line change
@@ -50,9 +50,15 @@ pub enum ControlBraceStyle {
5050
}
5151

5252
#[config_type]
53+
/// How to treat the semicolon that is optional for final diverging expressions
54+
/// (`return`/`break`/`continue`).
5355
pub enum TrailingSemicolon {
56+
/// Always rewrite `return;` and `break;` expressions to have a trailing semicolon,
57+
/// unless the block is a single-line block, e.g. `let PAT = e else { return }`.
5458
Always,
59+
/// Always return `return` and `break` expressions to remove the trailing semicolon.
5560
Never,
61+
/// Preserve an existing trailing semicolon if it exists.
5662
Preserve,
5763
}
5864

0 commit comments

Comments
 (0)