Preparing report...

Report for github.com/bluecmd/fibrechannel

A    Great!    Found 11 issues across 17 files

Tweet

gofmt82%

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


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!


gocyclo94%

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.


golint47%

Golint is a linter for Go source code.

    • fibrechannel/encoding/generate.go
    • Line 1: warning: package comment should be of the form "Package encoding ..." (golint)
    • Line 13: warning: exported type Size should have comment or be unexported (golint)
    • Line 14: warning: exported type TypeDef should have comment or be unexported (golint)
    • Line 15: warning: exported type Function should have comment or be unexported (golint)
    • Line 16: warning: exported type Statement should have comment or be unexported (golint)
    • Line 19: warning: exported const Bits should have comment (or a comment on this block) or be unexported (golint)
    • Line 25: warning: exported var Uint8 should have comment or be unexported (golint)
    • Line 31: warning: exported type Type should have comment or be unexported (golint)
    • Line 47: warning: exported type Field should have comment or be unexported (golint)
    • Line 53: warning: exported type Struct should have comment or be unexported (golint)
    • Line 58: warning: exported method Struct.TypeName should have comment or be unexported (golint)
    • Line 62: warning: exported method Struct.Field should have comment or be unexported (golint)
    • Line 68: warning: exported method Struct.Consts should have comment or be unexported (golint)
    • Line 76: warning: exported method Struct.FindReference should have comment or be unexported (golint)
    • Line 88: warning: exported method Struct.Functions should have comment or be unexported (golint)
    • Line 135: warning: exported method Struct.Deser should have comment or be unexported (golint)
    • Line 147: warning: exported method Struct.TypeDefs should have comment or be unexported (golint)
    • Line 161: warning: exported method Struct.PreSer should have comment or be unexported (golint)
    • Line 173: warning: exported method Struct.Ser should have comment or be unexported (golint)
    • Line 185: warning: exported type NamedConstant should have comment or be unexported (golint)
    • Line 191: warning: exported type Constant should have comment or be unexported (golint)
    • Line 196: warning: exported type Enum should have comment or be unexported (golint)
    • Line 202: warning: exported method Enum.TypeName should have comment or be unexported (golint)
    • Line 206: warning: exported method Enum.FindReference should have comment or be unexported (golint)
    • Line 210: warning: exported method Enum.Consts should have comment or be unexported (golint)
    • Line 219: warning: exported method Enum.Functions should have comment or be unexported (golint)
    • Line 229: warning: exported method Enum.TypeDefs should have comment or be unexported (golint)
    • Line 233: warning: exported method Enum.Deser should have comment or be unexported (golint)
    • Line 237: warning: exported method Enum.PreSer should have comment or be unexported (golint)
    • Line 241: warning: exported method Enum.Ser should have comment or be unexported (golint)
    • Line 245: warning: exported type SwitchedType should have comment or be unexported (golint)
    • Line 252: warning: exported method SwitchedType.TypeName should have comment or be unexported (golint)
    • Line 256: warning: exported method SwitchedType.FindReference should have comment or be unexported (golint)
    • Line 260: warning: exported method SwitchedType.Consts should have comment or be unexported (golint)
    • Line 268: warning: exported method SwitchedType.Functions should have comment or be unexported (golint)
    • Line 276: warning: exported method SwitchedType.TypeDefs should have comment or be unexported (golint)
    • Line 284: warning: exported method SwitchedType.Deser should have comment or be unexported (golint)
    • Line 315: warning: exported method SwitchedType.PreSer should have comment or be unexported (golint)
    • Line 330: warning: exported method SwitchedType.Ser should have comment or be unexported (golint)
    • Line 347: warning: exported type Unsigned should have comment or be unexported (golint)
    • Line 351: warning: exported method Unsigned.TypeName should have comment or be unexported (golint)
    • Line 355: warning: exported method Unsigned.Consts should have comment or be unexported (golint)
    • Line 359: warning: exported method Unsigned.Functions should have comment or be unexported (golint)
    • Line 363: warning: exported method Unsigned.TypeDefs should have comment or be unexported (golint)
    • Line 367: warning: exported method Unsigned.FindReference should have comment or be unexported (golint)
    • Line 379: warning: exported method Unsigned.Deser should have comment or be unexported (golint)
    • Line 383: warning: exported method Unsigned.PreSer should have comment or be unexported (golint)
    • Line 387: warning: exported method Unsigned.Ser should have comment or be unexported (golint)
    • Line 391: warning: exported type ByteArray should have comment or be unexported (golint)
    • Line 395: warning: exported method ByteArray.TypeName should have comment or be unexported (golint)
    • Line 399: warning: exported method ByteArray.Consts should have comment or be unexported (golint)
    • Line 403: warning: exported method ByteArray.Functions should have comment or be unexported (golint)
    • Line 407: warning: exported method ByteArray.TypeDefs should have comment or be unexported (golint)
    • Line 411: warning: exported method ByteArray.FindReference should have comment or be unexported (golint)
    • Line 415: warning: exported method ByteArray.Deser should have comment or be unexported (golint)
    • Line 419: warning: exported method ByteArray.PreSer should have comment or be unexported (golint)
    • Line 423: warning: exported method ByteArray.Ser should have comment or be unexported (golint)
    • Line 427: warning: exported type Object should have comment or be unexported (golint)
    • Line 431: warning: exported method Object.TypeName should have comment or be unexported (golint)
    • Line 435: warning: exported method Object.Consts should have comment or be unexported (golint)
    • Line 439: warning: exported method Object.Functions should have comment or be unexported (golint)
    • Line 443: warning: exported method Object.TypeDefs should have comment or be unexported (golint)
    • Line 447: warning: exported method Object.Deser should have comment or be unexported (golint)
    • Line 452: warning: exported method Object.PreSer should have comment or be unexported (golint)
    • Line 456: warning: exported method Object.Ser should have comment or be unexported (golint)
    • Line 461: warning: exported method Object.FindReference should have comment or be unexported (golint)
    • Line 465: warning: exported type Skip should have comment or be unexported (golint)
    • Line 469: warning: exported method Skip.TypeName should have comment or be unexported (golint)
    • Line 473: warning: exported method Skip.Consts should have comment or be unexported (golint)
    • Line 477: warning: exported method Skip.Functions should have comment or be unexported (golint)
    • Line 481: warning: exported method Skip.TypeDefs should have comment or be unexported (golint)
    • Line 493: warning: exported method Skip.Deser should have comment or be unexported (golint)
    • Line 497: warning: exported method Skip.PreSer should have comment or be unexported (golint)
    • Line 501: warning: exported method Skip.Ser should have comment or be unexported (golint)
    • Line 505: warning: exported method Skip.FindReference should have comment or be unexported (golint)
    • Line 509: warning: exported type Array should have comment or be unexported (golint)
    • Line 514: warning: exported method Array.TypeName should have comment or be unexported (golint)
    • Line 518: warning: exported method Array.Consts should have comment or be unexported (golint)
    • Line 522: warning: exported method Array.Functions should have comment or be unexported (golint)
    • Line 526: warning: exported method Array.TypeDefs should have comment or be unexported (golint)
    • Line 530: warning: exported method Array.FindReference should have comment or be unexported (golint)
    • Line 535: warning: exported method Array.Deser should have comment or be unexported (golint)
    • Line 547: warning: exported method Array.PreSer should have comment or be unexported (golint)
    • Line 559: warning: exported method Array.Ser should have comment or be unexported (golint)
    • Line 571: warning: exported function NewStruct should have comment or be unexported (golint)
    • Line 577: warning: exported function Generate should have comment or be unexported (golint)
    • fibrechannel/encoding/runtime.go
    • Line 8: warning: exported type Reader should have comment or be unexported (golint)
    • Line 14: warning: exported type Writer should have comment or be unexported (golint)
    • Line 30: warning: exported method Reader.Skip should have comment or be unexported (golint)
    • Line 38: warning: exported method Reader.ReadObject should have comment or be unexported (golint)
    • Line 54: warning: exported method Writer.Skip should have comment or be unexported (golint)
    • Line 62: warning: exported method Writer.WriteObject should have comment or be unexported (golint)
    • fibrechannel/swils/swils.go
    • Line 10: warning: exported type Command should have comment or be unexported (golint)
    • Line 13: warning: exported const CmdSWRJT should have comment (or a comment on this block) or be unexported (golint)
    • Line 34: warning: comment on exported const CmdESC should be of the form "CmdESC ..." (golint)
    • Line 43: warning: exported type Frame should have comment or be unexported (golint)
    • Line 49: warning: exported method Frame.ReadFrom should have comment or be unexported (golint)
    • Line 53: warning: exported method Frame.PostUnmarshal should have comment or be unexported (golint)
    • Line 73: warning: exported method Frame.PreMarshal should have comment or be unexported (golint)
    • Line 83: warning: exported method Frame.WriteTo should have comment or be unexported (golint)
    • fibrechannel/common/utils.go
    • Line 16: warning: exported type SerDes should have comment or be unexported (golint)
    • Line 21: warning: exported function TestFrameFiles should have comment or be unexported (golint)
    • fibrechannel/encoding/bitstruct.go
    • Line 19: warning: exported type BitStruct should have comment or be unexported (golint)
    • Line 25: warning: exported method BitStruct.BoolBit should have comment or be unexported (golint)
    • Line 36: warning: exported method BitStruct.SkipBit should have comment or be unexported (golint)
    • Line 40: warning: exported method BitStruct.IntField should have comment or be unexported (golint)
    • Line 77: warning: exported method BitStruct.TypeName should have comment or be unexported (golint)
    • Line 81: warning: exported method BitStruct.Consts should have comment or be unexported (golint)
    • Line 85: warning: exported method BitStruct.Functions should have comment or be unexported (golint)
    • Line 89: warning: exported method BitStruct.TypeDefs should have comment or be unexported (golint)
    • Line 103: warning: exported method BitStruct.Deser should have comment or be unexported (golint)
    • Line 108: warning: should omit 2nd value from range; this loop is equivalent to `for i := range ...` (golint)
    • Line 127: warning: exported method BitStruct.PreSer should have comment or be unexported (golint)
    • Line 131: warning: exported method BitStruct.Ser should have comment or be unexported (golint)
    • Line 164: warning: exported method BitStruct.FindReference should have comment or be unexported (golint)
    • Line 173: warning: exported function NewBitStruct should have comment or be unexported (golint)
    • fibrechannel/encoding/encoding.go
    • Line 67: warning: exported function ReadFromAndPost should have comment or be unexported (golint)
    • Line 78: warning: comment on exported function ReadFrom should be of the form "ReadFrom ..." (golint)
    • Line 119: warning: if block ends with a return statement, so drop this else and outdent its block (golint)
    • Line 143: warning: if block ends with a return statement, so drop this else and outdent its block (golint)
    • Line 153: warning: exported function WriteToAndPre should have comment or be unexported (golint)
    • Line 160: warning: comment on exported function WriteTo should be of the form "WriteTo ..." (golint)
    • fibrechannel/swils/elp.go
    • Line 10: warning: exported type ELP should have comment or be unexported (golint)
    • Line 25: warning: exported method ELP.ReadFrom should have comment or be unexported (golint)
    • Line 29: warning: exported method ELP.WriteTo should have comment or be unexported (golint)
    • fibrechannel/fcoe/fcoe.go
    • Line 12: warning: exported const EtherType should have comment (or a comment on this block) or be unexported (golint)
    • Line 38: warning: exported type Frame should have comment or be unexported (golint)
    • Line 49: warning: exported method Frame.UnmarshalBinary should have comment or be unexported (golint)
    • Line 69: warning: exported method Frame.Checksum should have comment or be unexported (golint)
    • Line 81: warning: exported method Frame.MarshalBinary should have comment or be unexported (golint)
    • fibrechannel/common/common.go
    • Line 9: warning: exported type WWN should have comment or be unexported (golint)
    • Line 16: warning: exported method WWN.ReadFrom should have comment or be unexported (golint)
    • Line 23: warning: exported method WWN.WriteTo should have comment or be unexported (golint)
    • Line 30: warning: exported type Uint16SizedByteArray should have comment or be unexported (golint)
    • Line 32: warning: exported method Uint16SizedByteArray.ReadFrom should have comment or be unexported (golint)
    • Line 48: warning: exported method Uint16SizedByteArray.WriteTo should have comment or be unexported (golint)

license100%

Checks whether your project has a LICENSE file.

No problems detected. Good job!


ineffassign100%

IneffAssign detects ineffectual assignments in Go code.

No problems detected. Good job!


misspell100%

Misspell Finds commonly misspelled English words

No problems detected. Good job!