Skip to content

Commit

Permalink
feat: add literal method for Op (#5)
Browse files Browse the repository at this point in the history
Co-authored-by: caiweiwei.cww <[email protected]>
  • Loading branch information
jjeffcaii and caiweiwei.cww authored Mar 27, 2022
1 parent d1149fb commit bc9df35
Show file tree
Hide file tree
Showing 2 changed files with 6 additions and 0 deletions.
Binary file removed .go.mod.swp
Binary file not shown.
6 changes: 6 additions & 0 deletions opcode/opcode.go
Original file line number Diff line number Diff line change
Expand Up @@ -244,3 +244,9 @@ func (o Op) Restore(ctx *format.RestoreCtx) error {
}
return nil
}

// Literal returns the literal string.
func (o Op) Literal() string {
info := &ops[o]
return info.literal
}

0 comments on commit bc9df35

Please sign in to comment.