Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
B
bookmark
Project
Project
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
JIRA
JIRA
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Registry
Registry
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
liuyuhang
bookmark
Commits
80f1acd4
Commit
80f1acd4
authored
Nov 26, 2018
by
liuyuhang
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Update linter_warning处理.md
parent
a272ebad
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
4 additions
and
5 deletions
+4
-5
linter_warning处理.md
linter_warning处理.md
+4
-5
No files found.
linter_warning处理.md
View file @
80f1acd4
## 本地
查看自己所修改模块golint warning的命令:
## 本地
查看自己所修改模块golint warning的命令:
...
...
@@ -194,6 +194,7 @@ func (acc *DB) depositBalance(execaddr string, amount int64) (*types.Receipt, er
### 2、
> * ineffectual assignment to end
```
func maxSubList(list []time.Duration) (sub []time.Duration) {
start := 0
...
...
@@ -202,7 +203,6 @@ func maxSubList(list []time.Duration) (sub []time.Duration) {
return list
}
for i := 0; i < len(list); i++ {
.....
if abs(nextheight-list[i]) > time.Millisecond*100 {
end = i + 1
if len(sub) < (end - start) {
...
...
@@ -217,7 +217,7 @@ func maxSubList(list []time.Duration) (sub []time.Duration) {
}
```
改为
改为
:
```
func maxSubList(list []time.Duration) (sub []time.Duration) {
if len(list) == 0 {
...
...
@@ -240,4 +240,4 @@ func maxSubList(list []time.Duration) (sub []time.Duration) {
}
}
```
\ No newline at end of file
```
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment