Add new rule
This commit is contained in:
parent
d0dd319de2
commit
0e0e66775e
|
|
@ -242,7 +242,13 @@ custom_rules:
|
|||
redundant_type_annotation_bool:
|
||||
name: "Redundant type annotation for Bool"
|
||||
regex: '((var|let)) *\w+ *((: *Bool *=)|((\w| |<|>|:)*= *BehaviorRelay<Bool>\( *value *:)) *((true)|(false))'
|
||||
message: "Using a type annotation for Bool is redundant"
|
||||
message: "Using a type annotation for Bool is redundant."
|
||||
severity: error
|
||||
|
||||
parameter_repetition:
|
||||
name: "Parameter repetition"
|
||||
regex: 'func \w*(\w+)(<.+>)?\((?i)\1'
|
||||
message: "The parameter name is actually used in the function name. Use _ instead."
|
||||
severity: error
|
||||
|
||||
# Rx
|
||||
|
|
|
|||
Loading…
Reference in New Issue