Skip to content

Commit 6e18b71

Browse files
committed
:let can set registers
1 parent aa9835c commit 6e18b71

File tree

1 file changed

+3
-1
lines changed

1 file changed

+3
-1
lines changed

src/cmd_line/commands/let.ts

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -33,6 +33,7 @@ import {
3333
import { displayValue } from '../../vimscript/expression/displayValue';
3434
import { VimError } from '../../error';
3535
import { bangParser } from '../../vimscript/parserUtils';
36+
import { Register } from '../../register/register';
3637

3738
type Unpack = {
3839
type: 'unpack';
@@ -249,7 +250,8 @@ export class LetCommand extends ExCommand {
249250
}
250251
context.setVariable(variable, newValue(variable, value), this.args.lock);
251252
} else if (variable.type === 'register') {
252-
// TODO
253+
vimState.recordedState.registerName = variable.name;
254+
Register.put(vimState, toString(value));
253255
} else if (variable.type === 'option') {
254256
// TODO
255257
} else if (variable.type === 'env_variable') {

0 commit comments

Comments
 (0)