Preparing report...

Report for github.com/rjkroege/edwood

A+    Excellent!    Found 38 issues across 96 files

Tweet

gofmt100%

Gofmt formats Go programs. We run gofmt -s on your code, where -s is for the "simplify" command

No problems detected. Good job!


go_vet100%

go vet examines Go source code and reports suspicious constructs, such as Printf calls whose arguments do not align with the format string.

No problems detected. Good job!


gocyclo70%

Gocyclo calculates cyclomatic complexities of functions in Go source code. The cyclomatic complexity of a function is calculated according to the following rules: 1 is the base complexity of a function +1 for each 'if', 'for', 'case', '&&' or '||' Go Report Card warns on functions with cyclomatic complexity > 15.

    • edwood/wind.go
    • Line 233: warning: cyclomatic complexity 17 of function (*Window).Resize() is high (> 15) (gocyclo)
    • edwood/edit.go
    • Line 443: warning: cyclomatic complexity 45 of function (*cmdParser).parse() is high (> 15) (gocyclo)
    • Line 612: warning: cyclomatic complexity 19 of function (*cmdParser).simpleaddr() is high (> 15) (gocyclo)
    • edwood/col.go
    • Line 338: warning: cyclomatic complexity 30 of function (*Column).Grow() is high (> 15) (gocyclo)
    • Line 503: warning: cyclomatic complexity 28 of function (*Column).DragWin() is high (> 15) (gocyclo)
    • Line 98: warning: cyclomatic complexity 17 of function (*Column).Add() is high (> 15) (gocyclo)
    • Line 207: warning: cyclomatic complexity 16 of function (*Column).Close() is high (> 15) (gocyclo)
    • edwood/xfid_test.go
    • Line 420: warning: cyclomatic complexity 19 of function TestXfidclose() is high (> 15) (gocyclo)
    • Line 255: warning: cyclomatic complexity 16 of function TestXfidopen() is high (> 15) (gocyclo)
    • edwood/text.go
    • Line 728: warning: cyclomatic complexity 71 of function (*Text).Type() is high (> 15) (gocyclo)
    • Line 1074: warning: cyclomatic complexity 30 of function (*Text).Select() is high (> 15) (gocyclo)
    • Line 1318: warning: cyclomatic complexity 19 of function (*Text).DoubleClick() is high (> 15) (gocyclo)
    • Line 1188: warning: cyclomatic complexity 18 of function (*Text).Show() is high (> 15) (gocyclo)
    • edwood/xfid.go
    • Line 541: warning: cyclomatic complexity 45 of function xfidctlwrite() is high (> 15) (gocyclo)
    • Line 376: warning: cyclomatic complexity 36 of function xfidwrite() is high (> 15) (gocyclo)
    • Line 80: warning: cyclomatic complexity 24 of function xfidopen() is high (> 15) (gocyclo)
    • Line 252: warning: cyclomatic complexity 22 of function xfidread() is high (> 15) (gocyclo)
    • Line 178: warning: cyclomatic complexity 21 of function xfidclose() is high (> 15) (gocyclo)
    • Line 713: warning: cyclomatic complexity 19 of function xfideventwrite() is high (> 15) (gocyclo)
    • edwood/acme.go
    • Line 343: warning: cyclomatic complexity 42 of function MovedMouse() is high (> 15) (gocyclo)
    • Line 39: warning: cyclomatic complexity 26 of function main() is high (> 15) (gocyclo)
    • Line 516: warning: cyclomatic complexity 20 of function waitthread() is high (> 15) (gocyclo)
    • Line 464: warning: cyclomatic complexity 19 of function keyboardthread() is high (> 15) (gocyclo)
    • edwood/fsys.go
    • Line 315: warning: cyclomatic complexity 20 of function (*fileServer).walk() is high (> 15) (gocyclo)
    • edwood/internal/regexp/exec.go
    • Line 397: warning: cyclomatic complexity 32 of function (*Regexp).doOnePass() is high (> 15) (gocyclo)
    • Line 260: warning: cyclomatic complexity 22 of function (*machine).step() is high (> 15) (gocyclo)
    • Line 175: warning: cyclomatic complexity 20 of function (*machine).match() is high (> 15) (gocyclo)
    • Line 317: warning: cyclomatic complexity 16 of function (*machine).add() is high (> 15) (gocyclo)
    • edwood/row.go
    • Line 535: warning: cyclomatic complexity 21 of function (*Row).loadimpl() is high (> 15) (gocyclo)
    • Line 135: warning: cyclomatic complexity 18 of function (*Row).DragCol() is high (> 15) (gocyclo)
    • Line 436: warning: cyclomatic complexity 18 of function (*Row).loadhelper() is high (> 15) (gocyclo)
    • Line 334: warning: cyclomatic complexity 17 of function (*Row).dump() is high (> 15) (gocyclo)
    • edwood/addr.go
    • Line 212: warning: cyclomatic complexity 43 of function address() is high (> 15) (gocyclo)
    • Line 60: warning: cyclomatic complexity 41 of function number() is high (> 15) (gocyclo)
    • edwood/ecmd.go
    • Line 45: warning: cyclomatic complexity 28 of function cmdexec() is high (> 15) (gocyclo)
    • Line 910: warning: cyclomatic complexity 28 of function cmdaddress() is high (> 15) (gocyclo)
    • Line 1116: warning: cyclomatic complexity 22 of function lineaddr() is high (> 15) (gocyclo)
    • Line 342: warning: cyclomatic complexity 21 of function s_cmd() is high (> 15) (gocyclo)
    • edwood/util.go
    • Line 192: warning: cyclomatic complexity 21 of function makenewwindow() is high (> 15) (gocyclo)
    • edwood/exec.go
    • Line 833: warning: cyclomatic complexity 38 of function runproc() is high (> 15) (gocyclo)
    • Line 124: warning: cyclomatic complexity 31 of function execute() is high (> 15) (gocyclo)
    • Line 262: warning: cyclomatic complexity 18 of function cut() is high (> 15) (gocyclo)
    • Line 496: warning: cyclomatic complexity 17 of function putfile() is high (> 15) (gocyclo)
    • edwood/look.go
    • Line 354: warning: cyclomatic complexity 37 of function expandfile() is high (> 15) (gocyclo)
    • Line 62: warning: cyclomatic complexity 32 of function look3() is high (> 15) (gocyclo)
    • Line 265: warning: cyclomatic complexity 17 of function search() is high (> 15) (gocyclo)
    • Line 527: warning: cyclomatic complexity 16 of function openfile() is high (> 15) (gocyclo)

golint90%

Golint is a linter for Go source code.

    • edwood/internal/regexp/onepass.go
    • Line 246: warning: don't use underscores in Go names; var p_A_Other should be pAOther (golint)
    • Line 247: warning: don't use underscores in Go names; var p_A_Alt should be pAAlt (golint)
    • Line 265: warning: don't use underscores in Go names; var p_B_Alt should be pBAlt (golint)
    • Line 266: warning: don't use underscores in Go names; var p_B_Other should be pBOther (golint)
    • edwood/internal/draw/9fans.go
    • Line 10: warning: exported const Refnone should have comment (or a comment on this block) or be unexported (golint)
    • Line 37: warning: exported type Color should have comment or be unexported (golint)
    • Line 38: warning: exported type Cursor should have comment or be unexported (golint)
    • Line 42: warning: exported type Keyboardctl should have comment or be unexported (golint)
    • Line 43: warning: exported type Mousectl should have comment or be unexported (golint)
    • Line 44: warning: exported type Mouse should have comment or be unexported (golint)
    • Line 45: warning: exported type Pix should have comment or be unexported (golint)
    • Line 48: warning: exported var Init should have comment or be unexported (golint)
    • Line 50: warning: exported function Main should have comment or be unexported (golint)
    • Line 54: warning: exported type Device should have comment or be unexported (golint)
    • Line 56: warning: exported method Device.NewDisplay should have comment or be unexported (golint)
    • edwood/internal/draw/interface.go
    • Line 5: warning: exported type Display should have comment or be unexported (golint)
    • Line 26: warning: exported type Image should have comment or be unexported (golint)
    • Line 37: warning: exported type Font should have comment or be unexported (golint)
    • edwood/internal/file/file_hash.go
    • Line 10: warning: exported type Hash should have comment or be unexported (golint)
    • Line 12: warning: exported var EmptyHash should have comment or be unexported (golint)
    • Line 14: warning: exported method Hash.Set should have comment or be unexported (golint)
    • Line 21: warning: exported method Hash.Eq should have comment or be unexported (golint)
    • Line 25: warning: exported function CalcHash should have comment or be unexported (golint)
    • Line 29: warning: exported function HashFor should have comment or be unexported (golint)

license100%

Checks whether your project has a LICENSE file.

No problems detected. Good job!


ineffassign89%

IneffAssign detects ineffectual assignments in Go code.

    • edwood/exec.go
    • Line 825: warning: ineffectual assignment to cpid (ineffassign)
    • Line 959: warning: ineffectual assignment to fs (ineffassign)
    • Line 1051: warning: ineffectual assignment to autoindent (ineffassign)

misspell97%

Misspell Finds commonly misspelled English words

    • edwood/edit_test.go
    • Line 31: warning: "nto" is a misspelling of "not" (misspell)
    • Line 32: warning: "nto" is a misspelling of "not" (misspell)
    • Line 33: warning: "nto" is a misspelling of "not" (misspell)
    • Line 34: warning: "nto" is a misspelling of "not" (misspell)
    • Line 35: warning: "nto" is a misspelling of "not" (misspell)
    • Line 38: warning: "nto" is a misspelling of "not" (misspell)
    • Line 39: warning: "nto" is a misspelling of "not" (misspell)
    • Line 40: warning: "nto" is a misspelling of "not" (misspell)
    • Line 46: warning: "nto" is a misspelling of "not" (misspell)
    • Line 47: warning: "nto" is a misspelling of "not" (misspell)
    • Line 48: warning: "nto" is a misspelling of "not" (misspell)
    • Line 52: warning: "nto" is a misspelling of "not" (misspell)
    • Line 53: warning: "nto" is a misspelling of "not" (misspell)
    • Line 54: warning: "nto" is a misspelling of "not" (misspell)
    • Line 59: warning: "nto" is a misspelling of "not" (misspell)
    • Line 60: warning: "nto" is a misspelling of "not" (misspell)
    • Line 61: warning: "nto" is a misspelling of "not" (misspell)
    • Line 62: warning: "nto" is a misspelling of "not" (misspell)
    • Line 66: warning: "nto" is a misspelling of "not" (misspell)
    • Line 67: warning: "nto" is a misspelling of "not" (misspell)
    • Line 68: warning: "nto" is a misspelling of "not" (misspell)
    • Line 69: warning: "nto" is a misspelling of "not" (misspell)
    • Line 73: warning: "nto" is a misspelling of "not" (misspell)
    • Line 74: warning: "nto" is a misspelling of "not" (misspell)
    • Line 78: warning: "nto" is a misspelling of "not" (misspell)
    • Line 79: warning: "nto" is a misspelling of "not" (misspell)
    • Line 80: warning: "nto" is a misspelling of "not" (misspell)
    • Line 83: warning: "nto" is a misspelling of "not" (misspell)
    • Line 86: warning: "nto" is a misspelling of "not" (misspell)
    • Line 87: warning: "nto" is a misspelling of "not" (misspell)
    • Line 93: warning: "nto" is a misspelling of "not" (misspell)
    • Line 94: warning: "nto" is a misspelling of "not" (misspell)
    • Line 95: warning: "nto" is a misspelling of "not" (misspell)
    • Line 96: warning: "nto" is a misspelling of "not" (misspell)
    • Line 143: warning: "nto" is a misspelling of "not" (misspell)
    • Line 357: warning: "nto" is a misspelling of "not" (misspell)
    • Line 361: warning: "nto" is a misspelling of "not" (misspell)