MCPcopy
hub / github.com/fogleman/nes / Flags

Method Flags

nes/cpu.go:356–367  ·  view source on GitHub ↗

Flags returns the processor status flags

()

Source from the content-addressed store, hash-verified

354
355// Flags returns the processor status flags
356func (cpu *CPU) Flags() byte {
357 var flags byte
358 flags |= cpu.C << 0
359 flags |= cpu.Z << 1
360 flags |= cpu.I << 2
361 flags |= cpu.D << 3
362 flags |= cpu.B << 4
363 flags |= cpu.U << 5
364 flags |= cpu.V << 6
365 flags |= cpu.N << 7
366 return flags
367}
368
369// SetFlags sets the processor status flags
370func (cpu *CPU) SetFlags(flags byte) {

Callers 2

PrintInstructionMethod · 0.95
phpMethod · 0.95

Calls

no outgoing calls

Tested by

no test coverage detected