Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
G
Geth-Modification
Project
Project
Details
Activity
Releases
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
张蕾
Geth-Modification
Commits
5ba9225f
Commit
5ba9225f
authored
Sep 07, 2017
by
nkbai
Committed by
Felix Lange
Sep 07, 2017
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
accounts/abi/bind: pass non-empty directory when calling goimports (#15070)
parent
fc87bc5f
Changes
2
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
2 additions
and
2 deletions
+2
-2
bind.go
accounts/abi/bind/bind.go
+1
-1
bind_test.go
accounts/abi/bind/bind_test.go
+1
-1
No files found.
accounts/abi/bind/bind.go
View file @
5ba9225f
...
...
@@ -122,7 +122,7 @@ func Bind(types []string, abis []string, bytecodes []string, pkg string, lang La
}
// For Go bindings pass the code through goimports to clean it up and double check
if
lang
==
LangGo
{
code
,
err
:=
imports
.
Process
(
""
,
buffer
.
Bytes
(),
nil
)
code
,
err
:=
imports
.
Process
(
"
.
"
,
buffer
.
Bytes
(),
nil
)
if
err
!=
nil
{
return
""
,
fmt
.
Errorf
(
"%v
\n
%s"
,
err
,
buffer
)
}
...
...
accounts/abi/bind/bind_test.go
View file @
5ba9225f
...
...
@@ -459,7 +459,7 @@ func TestBindings(t *testing.T) {
}
// Skip the test if the go-ethereum sources are symlinked (https://github.com/golang/go/issues/14845)
linkTestCode
:=
fmt
.
Sprintf
(
"package linktest
\n
func CheckSymlinks(){
\n
fmt.Println(backends.NewSimulatedBackend(nil))
\n
}"
)
linkTestDeps
,
err
:=
imports
.
Process
(
""
,
[]
byte
(
linkTestCode
),
nil
)
linkTestDeps
,
err
:=
imports
.
Process
(
os
.
TempDir
()
,
[]
byte
(
linkTestCode
),
nil
)
if
err
!=
nil
{
t
.
Fatalf
(
"failed check for goimports symlink bug: %v"
,
err
)
}
...
...
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