Skip to content

Commit

Permalink
fix some typos in repository (#728)
Browse files Browse the repository at this point in the history
  • Loading branch information
ccoVeille committed Aug 8, 2022
1 parent 160dfbd commit fa350e6
Show file tree
Hide file tree
Showing 3 changed files with 6 additions and 6 deletions.
4 changes: 2 additions & 2 deletions PULL_REQUEST_TEMPLATE.md
Expand Up @@ -5,8 +5,8 @@
<!-- ### CHECKLIST ### -->
<!-- Please, describe in details what's your motivation for this PR -->
<!-- Did you add tests? -->
<!-- Does your code follows the coding style of the rest of the repository? -->
<!-- Does your code follow the coding style of the rest of the repository? -->
<!-- Does the Travis build passes? -->

<!-- ### FOOTER (OPTIONAL) ### -->
<!-- If you're closing an issue add "Closes #XXXX" in your comment. This way, the PR will be linked to the issue automatically. -->
<!-- If you're closing an issue, add "Closes #XXXX" in your comment. This way, the PR will be linked to the issue automatically. -->
2 changes: 1 addition & 1 deletion README.md
Expand Up @@ -471,7 +471,7 @@ List of all available rules. The rules ported from `golint` are left unchanged a
| [`import-shadowing`](./RULES_DESCRIPTIONS.md#import-shadowing) | n/a | Spots identifiers that shadow an import | no | no |
| [`bare-return`](./RULES_DESCRIPTIONS.md#bare-return) | n/a | Warns on bare returns | no | no |
| [`unused-receiver`](./RULES_DESCRIPTIONS.md#unused-receiver) | n/a | Suggests to rename or remove unused method receivers | no | no |
| [`unhandled-error`](./RULES_DESCRIPTIONS.md#unhandled-error) | []string | Warns on unhandled errors returned by funcion calls | no | yes |
| [`unhandled-error`](./RULES_DESCRIPTIONS.md#unhandled-error) | []string | Warns on unhandled errors returned by function calls | no | yes |
| [`cognitive-complexity`](./RULES_DESCRIPTIONS.md#cognitive-complexity) | int | Sets restriction for maximum Cognitive complexity. | no | no |
| [`string-of-int`](./RULES_DESCRIPTIONS.md#string-of-int) | n/a | Warns on suspicious casts from int to string | no | yes |
| [`string-format`](./RULES_DESCRIPTIONS.md#string-format) | map | Warns on specific string literals that fail one or more user-configured regular expressions | no | no |
Expand Down
6 changes: 3 additions & 3 deletions rule/unconditional-recursion.go
Expand Up @@ -28,12 +28,12 @@ func (*UnconditionalRecursionRule) Name() string {
}

type funcDesc struct {
reciverID *ast.Ident
id *ast.Ident
receiverID *ast.Ident
id *ast.Ident
}

func (fd *funcDesc) equal(other *funcDesc) bool {
receiversAreEqual := (fd.reciverID == nil && other.reciverID == nil) || fd.reciverID != nil && other.reciverID != nil && fd.reciverID.Name == other.reciverID.Name
receiversAreEqual := (fd.receiverID == nil && other.receiverID == nil) || fd.receiverID != nil && other.receiverID != nil && fd.receiverID.Name == other.receiverID.Name
idsAreEqual := (fd.id == nil && other.id == nil) || fd.id.Name == other.id.Name

return receiversAreEqual && idsAreEqual
Expand Down

0 comments on commit fa350e6

Please sign in to comment.