Skip to content

Commit b9204a7

Browse files
committed
nvim: remove unnecessary codes
1 parent 620209e commit b9204a7

File tree

2 files changed

+2
-5
lines changed

2 files changed

+2
-5
lines changed

nvim/helpers.go

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -20,8 +20,6 @@ func NewBufferReader(v *Nvim, b Buffer) io.Reader {
2020
return &bufferReader{v: v, b: b}
2121
}
2222

23-
var lineEnd = []byte{'\n'}
24-
2523
// Read implements io.Reader.
2624
func (r *bufferReader) Read(p []byte) (n int, err error) {
2725
if r.err != nil {

nvim/types.go

Lines changed: 2 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -55,8 +55,7 @@ type CommandCompletionArgs struct {
5555

5656
// CursorPos returns the cursor position.
5757
func (a *CommandCompletionArgs) CursorPos() int {
58-
n := a.CursorPosString
59-
return n
58+
return a.CursorPosString
6059
}
6160

6261
// Mode represents a Nvim's current mode.
@@ -194,7 +193,7 @@ type ClientMethod struct {
194193
Async bool `msgpack:"async"`
195194

196195
// NArgs is the number of method arguments.
197-
NArgs ClientMethodNArgs `msgpack:"nargs"`
196+
NArgs ClientMethodNArgs
198197
}
199198

200199
// ClientMethodNArgs is the number of arguments. Could be a single integer or an array two integers, minimum and maximum inclusive.

0 commit comments

Comments
 (0)