Preparing report...

Report for github.com/pokemium/worldwide

A    Great!    Found 31 issues across 33 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!


gocyclo96%

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.


golint15%

Golint is a linter for Go source code.

    • worldwide/pkg/gbc/video/renderer.go
    • Line 7: warning: comment on exported type Renderer should be of the form "Renderer ..." (with optional leading article) (golint)
    • Line 53: warning: exported function NewRenderer should have comment or be unexported (golint)
    • Line 96: warning: comment on exported method Renderer.WriteVideoRegister should be of the form "WriteVideoRegister ..." (golint)
    • worldwide/pkg/gbc/video/video.go
    • Line 11: warning: comment on exported type Color should be of the form "Color ..." (with optional leading article) (golint)
    • Line 34: warning: exported type VRAM should have comment or be unexported (golint)
    • Line 68: warning: comment on exported var DmgColor should be of the form "DmgColor ..." (golint)
    • Line 75: warning: exported const BGP should have comment (or a comment on this block) or be unexported (golint)
    • Line 80: warning: exported function New should have comment or be unexported (golint)
    • Line 95: warning: exported method Video.Reset should have comment or be unexported (golint)
    • Line 132: warning: comment on exported method Video.SkipBIOS should be of the form "SkipBIOS ..." (golint)
    • Line 161: warning: comment on exported method Video.WritePalette should be of the form "WritePalette ..." (golint)
    • Line 242: warning: comment on exported method Video.SwitchBank should be of the form "SwitchBank ..." (golint)
    • Line 248: warning: comment on exported method Video.ProcessDots should be of the form "ProcessDots ..." (golint)
    • Line 259: warning: comment on exported method Video.EndMode0 should be of the form "EndMode0 ..." (golint)
    • Line 302: warning: comment on exported method Video.EndMode1 should be of the form "EndMode1 ..." (golint)
    • Line 335: warning: comment on exported method Video.EndMode2 should be of the form "EndMode2 ..." (golint)
    • Line 348: warning: comment on exported method Video.EndMode3 should be of the form "EndMode3 ..." (golint)
    • Line 376: warning: exported method Video.Mode should have comment or be unexported (golint)
    • Line 384: warning: comment on exported method Video.WriteLCDC should be of the form "WriteLCDC ..." (golint)
    • Line 413: warning: comment on exported method Video.WriteSTAT should be of the form "WriteSTAT ..." (golint)
    • Line 426: warning: comment on exported method Video.WriteLYC should be of the form "WriteLYC ..." (golint)
    • worldwide/pkg/gbc/timer.go
    • Line 11: warning: exported const GB_DMG_DIV_PERIOD should have comment (or a comment on this block) or be unexported (golint)
    • Line 14: warning: exported type Timer should have comment or be unexported (golint)
    • Line 21: warning: exported function NewTimer should have comment or be unexported (golint)
    • worldwide/pkg/util/model.go
    • Line 3: warning: exported type GBModel should have comment or be unexported (golint)
    • Line 6: warning: exported const GB_MODEL_AUTODETECT should have comment (or a comment on this block) or be unexported (golint)
    • worldwide/pkg/gbc/scheduler/event.go
    • Line 3: warning: exported type EventName should have comment or be unexported (golint)
    • Line 6: warning: exported const TimerUpdate should have comment (or a comment on this block) or be unexported (golint)
    • Line 18: warning: exported type Event should have comment or be unexported (golint)
    • worldwide/pkg/emulator/debug/debug.go
    • Line 8: warning: exported const TILE_PER_ROW should have comment (or a comment on this block) or be unexported (golint)
    • Line 11: warning: exported type Debugger should have comment or be unexported (golint)
    • Line 15: warning: exported function New should have comment or be unexported (golint)
    • worldwide/pkg/emulator/emulator.go
    • Line 18: warning: exported type Emulator should have comment or be unexported (golint)
    • Line 26: warning: exported function New should have comment or be unexported (golint)
    • Line 40: warning: exported method Emulator.Update should have comment or be unexported (golint)
    • Line 62: warning: exported method Emulator.Draw should have comment or be unexported (golint)
    • Line 73: warning: exported method Emulator.Layout should have comment or be unexported (golint)
    • worldwide/pkg/gbc/optable.go
    • Line 4: warning: exported const INS_ADC should have comment (or a comment on this block) or be unexported (golint)
    • Line 53: warning: exported const OP_NONE should have comment (or a comment on this block) or be unexported (golint)
    • Line 55: warning: don't use underscores in Go names; const OP_d16 should be OPD16 (golint)
    • Line 57: warning: don't use underscores in Go names; const OP_A should be OPA (golint)
    • Line 59: warning: don't use underscores in Go names; const OP_B should be OPB (golint)
    • Line 60: warning: don't use underscores in Go names; const OP_d8 should be OPD8 (golint)
    • Line 61: warning: don't use underscores in Go names; const OP_a16_PAREN should be OPA16PAREN (golint)
    • Line 63: warning: don't use underscores in Go names; const OP_SP_PLUS_r8 should be OPSPPLUSR8 (golint)
    • Line 65: warning: don't use underscores in Go names; const OP_C should be OPC (golint)
    • Line 69: warning: don't use underscores in Go names; const OP_D should be OPD (golint)
    • Line 70: warning: don't use underscores in Go names; const OP_r8 should be OPR8 (golint)
    • Line 71: warning: don't use underscores in Go names; const OP_a8_PAREN should be OPA8PAREN (golint)
    • Line 72: warning: don't use underscores in Go names; const OP_a16 should be OPA16 (golint)
    • Line 73: warning: don't use underscores in Go names; const OP_E should be OPE (golint)
    • Line 76: warning: don't use underscores in Go names; const OP_H should be OPH (golint)
    • Line 77: warning: don't use underscores in Go names; const OP_L should be OPL (golint)
    • Line 78: warning: don't use underscores in Go names; const OP_Z should be OPZ (golint)
    • Line 84: warning: exported type Inst should have comment or be unexported (golint)
    • worldwide/pkg/util/util.go
    • Line 45: warning: exported function SetBit16 should have comment or be unexported (golint)
    • Line 54: warning: exported function SetBit8 should have comment or be unexported (golint)
    • Line 63: warning: exported function Bool2Int should have comment or be unexported (golint)
    • Line 69: warning: exported function Bool2U8 should have comment or be unexported (golint)
    • Line 75: warning: exported function Bool2U16 should have comment or be unexported (golint)
    • Line 81: warning: exported function Bool2U32 should have comment or be unexported (golint)
    • Line 87: warning: exported function Bool2U64 should have comment or be unexported (golint)
    • Line 94: warning: exported function SetMSB should have comment or be unexported (golint)
    • Line 103: warning: exported function SetLSB should have comment or be unexported (golint)
    • Line 112: warning: exported var OpcodeToString should have comment or be unexported (golint)
    • worldwide/cmd/main.go
    • Line 20: warning: exported const ExitCodeOK should have comment (or a comment on this block) or be unexported (golint)
    • worldwide/pkg/gbc/rtc/rtc.go
    • Line 11: warning: exported const S should have comment (or a comment on this block) or be unexported (golint)
    • Line 30: warning: exported function New should have comment or be unexported (golint)
    • Line 32: warning: exported method RTC.IncrementSecond should have comment or be unexported (golint)
    • worldwide/pkg/emulator/server.go
    • Line 10: warning: exported method Emulator.RunServer should have comment or be unexported (golint)
    • Line 21: warning: exported method Emulator.Pause should have comment or be unexported (golint)
    • Line 22: warning: exported method Emulator.Continue should have comment or be unexported (golint)
    • worldwide/pkg/gbc/apu/apu.go
    • Line 14: warning: exported const SAMPLE_RATE should have comment (or a comment on this block) or be unexported (golint)
    • Line 43: warning: comment on exported function New should be of the form "New ..." (golint)
    • Line 71: warning: comment on exported method APU.Update should be of the form "Update ..." (golint)
    • Line 94: warning: exported method APU.Buffer should have comment or be unexported (golint)
    • Line 327: warning: exported method APU.LogSoundState should have comment or be unexported (golint)
    • worldwide/pkg/gbc/video/constants.go
    • Line 4: warning: exported const HORIZONTAL_PIXELS should have comment (or a comment on this block) or be unexported (golint)
    • Line 17: warning: exported const GB_BASE_MAP should have comment (or a comment on this block) or be unexported (golint)
    • Line 23: warning: exported const OBJ_PRIORITY should have comment (or a comment on this block) or be unexported (golint)
    • Line 28: warning: exported const PAL_BG should have comment (or a comment on this block) or be unexported (golint)
    • Line 37: warning: exported const BgEnable should have comment (or a comment on this block) or be unexported (golint)
    • Line 48: warning: exported const ObjAttrBank should have comment (or a comment on this block) or be unexported (golint)
    • Line 56: warning: comment on exported const GB_REG_IF should be of the form "GB_REG_IF ..." (golint)
    • Line 58: warning: exported const GB_REG_IE should have comment (or a comment on this block) or be unexported (golint)
    • worldwide/pkg/gbc/video/oam.go
    • Line 3: warning: exported type OAM should have comment or be unexported (golint)
    • Line 8: warning: exported function NewOAM should have comment or be unexported (golint)
    • Line 16: warning: exported method OAM.Get should have comment or be unexported (golint)
    • Line 22: warning: exported method OAM.Set should have comment or be unexported (golint)
    • Line 28: warning: comment on exported type Obj should be of the form "Obj ..." (with optional leading article) (golint)
    • Line 60: warning: exported type Sprite should have comment or be unexported (golint)
    • worldwide/pkg/gbc/joypad/joypad.go
    • Line 6: warning: exported const A should have comment (or a comment on this block) or be unexported (golint)
    • Line 23: warning: exported function New should have comment or be unexported (golint)
    • Line 46: warning: receiver name j should be consistent with previous receiver name pad for Joypad (golint)
    • worldwide/pkg/gbc/scheduler/scheduler.go
    • Line 14: warning: exported function New should have comment or be unexported (golint)
    • Line 15: warning: exported method Scheduler.Cycle should have comment or be unexported (golint)
    • Line 16: warning: exported method Scheduler.Add should have comment or be unexported (golint)
    • Line 18: warning: exported method Scheduler.Next should have comment or be unexported (golint)
    • Line 25: warning: exported method Scheduler.ScheduleEvent should have comment or be unexported (golint)
    • Line 78: warning: exported method Scheduler.DescheduleEvent should have comment or be unexported (golint)
    • Line 90: warning: if block ends with a return statement, so drop this else and outdent its block (golint)
    • Line 101: warning: exported method Scheduler.DoEvent should have comment or be unexported (golint)
    • Line 110: warning: exported method Scheduler.Until should have comment or be unexported (golint)
    • worldwide/pkg/gbc/register.go
    • Line 4: warning: exported const A should have comment (or a comment on this block) or be unexported (golint)
    • Line 15: warning: exported const AF should have comment (or a comment on this block) or be unexported (golint)
    • Line 36: warning: exported method Register.R16 should have comment or be unexported (golint)
    • Line 79: warning: exported method Register.AF should have comment or be unexported (golint)
    • Line 86: warning: exported method Register.BC should have comment or be unexported (golint)
    • Line 93: warning: exported method Register.DE should have comment or be unexported (golint)
    • Line 100: warning: exported method Register.HL should have comment or be unexported (golint)
    • worldwide/pkg/gbc/cart/cart.go
    • Line 4: warning: exported const ROM should have comment (or a comment on this block) or be unexported (golint)
    • Line 19: warning: comment on exported function New should be of the form "New ..." (golint)
    • Line 37: warning: exported method Cartridge.HasRTC should have comment or be unexported (golint)
    • worldwide/pkg/gbc/gbc.go
    • Line 20: warning: comment on exported type ROM should be of the form "ROM ..." (with optional leading article) (golint)
    • Line 36: warning: comment on exported type WRAM should be of the form "WRAM ..." (with optional leading article) (golint)
    • Line 47: warning: exported type Dma should have comment or be unexported (golint)
    • Line 52: warning: exported type Hdma should have comment or be unexported (golint)
    • Line 59: warning: exported const NoIRQ should have comment (or a comment on this block) or be unexported (golint)
    • Line 67: warning: exported type CurInst should have comment or be unexported (golint)
    • Line 205: warning: exported function New should have comment or be unexported (golint)
    • Line 257: warning: comment on exported method GBC.Update should be of the form "Update ..." (golint)
    • Line 272: warning: exported method GBC.PanicHandler should have comment or be unexported (golint)
    • Line 315: warning: exported method GBC.Draw should have comment or be unexported (golint)
    • Line 325: warning: exported method GBC.Frame should have comment or be unexported (golint)
    • worldwide/pkg/emulator/audio/audio.go
    • Line 10: warning: exported var Stream should have comment or be unexported (golint)
    • Line 13: warning: exported function Init should have comment or be unexported (golint)
    • Line 25: warning: exported function Play should have comment or be unexported (golint)
    • Line 32: warning: exported function SetStream should have comment or be unexported (golint)
    • worldwide/pkg/emulator/save.go
    • Line 9: warning: comment on exported method Emulator.WriteSav should be of the form "WriteSav ..." (golint)
    • Line 62: warning: exported method Emulator.LoadSav should have comment or be unexported (golint)

license100%

Checks whether your project has a LICENSE file.

No problems detected. Good job!


ineffassign90%

IneffAssign detects ineffectual assignments in Go code.


misspell100%

Misspell Finds commonly misspelled English words

No problems detected. Good job!