You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: src/lint/features.md
+1Lines changed: 1 addition & 0 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -3,6 +3,7 @@
3
3
Below are listed the currently supported rules for linting:
4
4
5
5
## Spacing
6
+
- SpReserved, `sp_reserved`: around reserved words, such as `if`, `else`, `default`, `size`, `const` and `in`, except when a reserved word is used as an identifier (e.g., `local uint8 *data;`). Currently supported reserved words: `if`, `for` and `while`.
6
7
- SpBinop, `sp_binop`: spaces around binary operators except for derefencing operators (dot `a.b` and arrow `a->b` )
7
8
- SpTernary, `sp_ternary`: spaces around `?` and `:` in ternary conditional expressions
8
9
- SpBraces, `sp_brace`: spaces around braces (`{` and `}`)
Copy file name to clipboardExpand all lines: src/lint/rules/mod.rs
+14-1Lines changed: 14 additions & 1 deletion
Original file line number
Diff line number
Diff line change
@@ -4,12 +4,23 @@ pub mod indentation;
4
4
#[cfg(test)]
5
5
pubmod tests;
6
6
7
-
use spacing::{NspFunparRule,NspInparenRule,NspTrailingRule,NspUnaryRule,SpBracesRule,SpBinopRule,SpTernaryRule,SpPtrDeclRule,NspPtrDeclRule,SpPunctRule};
7
+
use spacing::{NspFunparRule,
8
+
NspInparenRule,
9
+
NspTrailingRule,
10
+
NspUnaryRule,
11
+
SpBracesRule,
12
+
SpBinopRule,
13
+
SpTernaryRule,
14
+
SpPtrDeclRule,
15
+
NspPtrDeclRule,
16
+
SpPunctRule,
17
+
SpReservedRule};
8
18
use indentation::{LongLinesRule,IndentNoTabRule,IndentCodeBlockRule,IndentClosingBraceRule,IndentParenExprRule,IndentSwitchCaseRule,IndentEmptyLoopRule};
0 commit comments