18 lines
361 B
Go
18 lines
361 B
Go
package asm
|
|
|
|
import (
|
|
"fmt"
|
|
|
|
"git.akyoto.dev/cli/q/src/build/cpu"
|
|
)
|
|
|
|
// RegisterRegister operates with two registers.
|
|
type RegisterRegister struct {
|
|
Destination cpu.Register
|
|
Source cpu.Register
|
|
}
|
|
|
|
// String returns a human readable version.
|
|
func (data *RegisterRegister) String() string {
|
|
return fmt.Sprintf("%s, %s", data.Destination, data.Source)
|
|
}
|