diff options
author | Charlie Stanton <charlie@shtanton.xyz> | 2023-04-20 09:25:51 +0100 |
---|---|---|
committer | Charlie Stanton <charlie@shtanton.xyz> | 2023-04-20 09:25:51 +0100 |
commit | 6a77b63c3cd4edb992b94e42c5a222a1480a3f33 (patch) | |
tree | 26402941684af420cf6f489ec7b56a74fdf473aa /main/parse.go | |
parent | 773c5e115fbb4e8b432e95e02216af9b23415ca8 (diff) | |
download | stred-go-6a77b63c3cd4edb992b94e42c5a222a1480a3f33.tar |
Add commands to append to and swap with the path and X registers
Diffstat (limited to 'main/parse.go')
-rw-r--r-- | main/parse.go | 8 |
1 files changed, 8 insertions, 0 deletions
diff --git a/main/parse.go b/main/parse.go index 9cc93e7..8211444 100644 --- a/main/parse.go +++ b/main/parse.go @@ -251,6 +251,14 @@ func (p *parser) parseBasicCommand(commandChar rune) Command { return PrintLiteralsCommand {items: items} case 'o': return NoopCommand{} + case 'x': + return SwapXRegCommand{} + case 'X': + return AppendXRegCommand{} + case 'k': + return SwapPathCommand{} + case 'K': + return AppendPathCommand{} default: panic("Invalid command") } |