Skip to content

Commit 3d91935

Browse files
authored
Merge pull request #2 from haya14busa/improve-ci
CI: introduce unused
2 parents 2a64524 + b0ccfe9 commit 3d91935

File tree

3 files changed

+2
-32
lines changed

3 files changed

+2
-32
lines changed

.travis.yml

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -8,9 +8,11 @@ install:
88
- go get -d -v -t ./...
99
- go get github.com/mattn/goveralls
1010
- go get github.com/golang/lint/golint
11+
- go get honnef.co/go/unused/cmd/unused
1112

1213
script:
1314
- go test -v -race ./...
1415
- goveralls -service=travis-ci
1516
- go vet ./...
1617
- golint -set_exit_status .
18+
- unused ./...

go/vimlfunc.go

Lines changed: 0 additions & 28 deletions
Original file line numberDiff line numberDiff line change
@@ -76,14 +76,6 @@ func init() {
7676

7777
type vimlList interface{}
7878

79-
func viml_call(f string, args ...interface{}) interface{} {
80-
panic("NotImplemented viml_call")
81-
}
82-
83-
func viml_char2nr(c string) int {
84-
panic("NotImplemented viml_char2nr")
85-
}
86-
8779
func viml_empty(obj interface{}) bool {
8880
return viml_len(obj) == 0
8981
}
@@ -124,10 +116,6 @@ func viml_escape(s string, chars string) string {
124116
return r
125117
}
126118

127-
func viml_extend(obj, item interface{}) interface{} {
128-
panic("NotImplemented viml_extend")
129-
}
130-
131119
func viml_join(lst vimlList, sep string) string {
132120
var ss []string
133121
s := reflect.ValueOf(lst)
@@ -137,10 +125,6 @@ func viml_join(lst vimlList, sep string) string {
137125
return strings.Join(ss, sep)
138126
}
139127

140-
func viml_keys(obj map[string]interface{}) []string {
141-
panic("NotImplemented viml_keys")
142-
}
143-
144128
func viml_len(obj interface{}) int {
145129
return reflect.ValueOf(obj).Len()
146130
}
@@ -157,10 +141,6 @@ func viml_range(start, end int) []int {
157141
return rs
158142
}
159143

160-
func viml_readfile(path string) []string {
161-
panic("NotImplemented viml_readfile")
162-
}
163-
164144
func viml_split(s string, sep string) []string {
165145
if sep == `\zs` {
166146
var ss []string
@@ -193,11 +173,3 @@ func viml_has_key(obj interface{}, key interface{}) bool {
193173
func viml_stridx(a, b string) int {
194174
return strings.Index(a, b)
195175
}
196-
197-
func viml_type(obj interface{}) int {
198-
panic("NotImplemented viml_type")
199-
}
200-
201-
func viml_ternary(cond bool, a interface{}, b interface{}) interface{} {
202-
panic("NotImplemented viml_ternary")
203-
}

go/vimlfunc_test.go

Lines changed: 0 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -5,10 +5,6 @@ import (
55
"testing"
66
)
77

8-
var vimArgs = []string{"-Nu", "NONE", "-i", "NONE", "-n"}
9-
10-
type testHandler struct{}
11-
128
func TestViml_len(t *testing.T) {
139
tests := []struct {
1410
in interface{}

0 commit comments

Comments
 (0)