We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
1 parent 922e8ba commit 1973b90Copy full SHA for 1973b90
src/config/options.rs
@@ -50,9 +50,15 @@ pub enum ControlBraceStyle {
50
}
51
52
#[config_type]
53
+/// How to treat the semicolon that is optional for final diverging expressions
54
+/// (`return`/`break`/`continue`).
55
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 }`.
58
Always,
59
+ /// Always return `return` and `break` expressions to remove the trailing semicolon.
60
Never,
61
+ /// Preserve an existing trailing semicolon if it exists.
62
Preserve,
63
64
0 commit comments