Skip to content

Commit e657309

Browse files
committed
ssh/terminal: use "reports whether" in IsTerminal doc
Go documentation style for boolean funcs is to say: // Foo reports whether ... func Foo() bool (rather than "returns true if") Change-Id: I6972d123ba99bbf3dbf95e876b45b2ecd98dd07c Reviewed-on: https://go-review.googlesource.com/c/151257 Run-TryBot: Tobias Klauser <tobias.klauser@gmail.com> TryBot-Result: Gobot Gobot <gobot@golang.org> Reviewed-by: Brad Fitzpatrick <bradfitz@golang.org>
1 parent c05539c commit e657309

File tree

4 files changed

+4
-4
lines changed

4 files changed

+4
-4
lines changed

ssh/terminal/util.go

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -25,7 +25,7 @@ type State struct {
2525
termios unix.Termios
2626
}
2727

28-
// IsTerminal returns true if the given file descriptor is a terminal.
28+
// IsTerminal returns whether the given file descriptor is a terminal.
2929
func IsTerminal(fd int) bool {
3030
_, err := unix.IoctlGetTermios(fd, ioctlReadTermios)
3131
return err == nil

ssh/terminal/util_plan9.go

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -21,7 +21,7 @@ import (
2121

2222
type State struct{}
2323

24-
// IsTerminal returns true if the given file descriptor is a terminal.
24+
// IsTerminal returns whether the given file descriptor is a terminal.
2525
func IsTerminal(fd int) bool {
2626
return false
2727
}

ssh/terminal/util_solaris.go

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -17,7 +17,7 @@ type State struct {
1717
termios unix.Termios
1818
}
1919

20-
// IsTerminal returns true if the given file descriptor is a terminal.
20+
// IsTerminal returns whether the given file descriptor is a terminal.
2121
func IsTerminal(fd int) bool {
2222
_, err := unix.IoctlGetTermio(fd, unix.TCGETA)
2323
return err == nil

ssh/terminal/util_windows.go

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -26,7 +26,7 @@ type State struct {
2626
mode uint32
2727
}
2828

29-
// IsTerminal returns true if the given file descriptor is a terminal.
29+
// IsTerminal returns whether the given file descriptor is a terminal.
3030
func IsTerminal(fd int) bool {
3131
var st uint32
3232
err := windows.GetConsoleMode(windows.Handle(fd), &st)

0 commit comments

Comments
 (0)